summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDongjin Kim <tobetter@gmail.com>2021-06-17 07:49:54 +0300
committerDongjin Kim <tobetter@gmail.com>2021-11-30 22:02:12 +0300
commit031bc403d14af2030c6c874e0b006e06a7a6ef73 (patch)
tree759b0044269218a0f0047492a1412182fa110514
parent86031e37dd614b45760699c922e5a7a0911d4ef0 (diff)
downloadu-boot-031bc403d14af2030c6c874e0b006e06a7a6ef73.tar.xz
ODROID-COMMON: cmd: fix to support 'ini' command
Signed-off-by: Dongjin Kim <tobetter@gmail.com> Change-Id: I01a6b35cd8d0ad95d2d216f6ca5d84dbd101cbcb
-rw-r--r--cmd/Kconfig5
-rw-r--r--cmd/ini.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/cmd/Kconfig b/cmd/Kconfig
index 051d3955fc..71a20abd00 100644
--- a/cmd/Kconfig
+++ b/cmd/Kconfig
@@ -729,6 +729,11 @@ config CMD_IDE
geting device info. It also enables the 'diskboot' command which
permits booting from an IDE drive.
+config CMD_INI
+ bool "ini - import data from an ini file into the env"
+ help
+ Enables the 'ini' command to import env data from an ini file.
+
config CMD_IO
bool "io - Support for performing I/O accesses"
help
diff --git a/cmd/ini.c b/cmd/ini.c
index 8656299447..d65356bce7 100644
--- a/cmd/ini.c
+++ b/cmd/ini.c
@@ -90,7 +90,7 @@ static char *memgets(char *str, int num, char **mem, size_t *memsize)
end = *mem + *memsize;
newline = 0;
}
- len = min((end - *mem) + newline, num);
+ len = min((int)(end - *mem) + newline, num);
memcpy(str, *mem, len);
if (len < num)
str[len] = '\0';