diff options
| author | Thomas Betker <[email protected]> | 2014-06-05 20:07:56 +0200 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2014-06-11 16:25:47 -0400 |
| commit | 73671dad49bf2368959b7bf0e30ba931ea95565c (patch) | |
| tree | ab8bfdab55cc81119814c5eb4a6ff782e88b3705 /common | |
| parent | 32e2c42a83e8676511e178e0285ea634bc4564fd (diff) | |
Check run_command() return code properly
run_command() returns 0 for success, 1 for failure. Fix places which
assume that failure is indicated by a negative return code.
Signed-off-by: Thomas Betker <[email protected]>
Acked-by: Simon Glass <[email protected]>
Tested-by: Simon Glass <[email protected]>
Tested-by: Stefan Roese <[email protected]>
Diffstat (limited to 'common')
| -rw-r--r-- | common/cmd_bootm.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c index 9b11c0ea18e..c06f4b730f3 100644 --- a/common/cmd_bootm.c +++ b/common/cmd_bootm.c @@ -1087,11 +1087,7 @@ U_BOOT_CMD( #if defined(CONFIG_CMD_BOOTD) int do_bootd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) { - int rcode = 0; - - if (run_command(getenv("bootcmd"), flag) < 0) - rcode = 1; - return rcode; + return run_command(getenv("bootcmd"), flag); } U_BOOT_CMD( |
