diff options
author | Stefano Babic <sbabic@denx.de> | 2014-08-08 10:18:40 +0200 |
---|---|---|
committer | Stefano Babic <sbabic@denx.de> | 2014-08-08 10:18:40 +0200 |
commit | c23154aab5825fec81d5500c53eaa686646c76b5 (patch) | |
tree | 32b0aafae49f664a65ced50981492bb031f006b8 /fs/fs.c | |
parent | cb07d74e2e0c0a41533b6bcd551af9bf2ebcf2bc (diff) | |
parent | 9d195a546179bc732aba9eacccf0a9a3db591288 (diff) |
Merge branch 'master' of git://git.denx.de/u-boot-arm
Diffstat (limited to 'fs/fs.c')
-rw-r--r-- | fs/fs.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -276,6 +276,7 @@ int do_load(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[], unsigned long pos; int len_read; unsigned long time; + char *ep; if (argc < 2) return CMD_RET_USAGE; @@ -286,7 +287,9 @@ int do_load(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[], return 1; if (argc >= 4) { - addr = simple_strtoul(argv[3], NULL, 16); + addr = simple_strtoul(argv[3], &ep, 16); + if (ep == argv[3] || *ep != '\0') + return CMD_RET_USAGE; } else { addr_str = getenv("loadaddr"); if (addr_str != NULL) |