summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2006-10-10 00:23:32 -0600
committerJon Loeliger <jdl@freescale.com>2006-10-12 08:42:03 -0500
commit1eaf3a5ff4960a46f3a9063568ba2af7883f07c5 (patch)
tree54b83be5f801444cb8c29789e43a058fbd4ee691 /common
parentc3c3b089adcee06df3afd4e8b00a3fea82263bcd (diff)
downloadblackbird-obmc-uboot-1eaf3a5ff4960a46f3a9063568ba2af7883f07c5.tar.gz
blackbird-obmc-uboot-1eaf3a5ff4960a46f3a9063568ba2af7883f07c5.zip
Fix possible uninitialized variable compiler warning.
When CONFIG_OF_FLAG_TREE is set, the compiler complains that 'len' in do_bootm_linux() may be uninitialized. There is no possibility in the current code that len will get used uninitialized, but this fix follows the existing convention of setting both len and data to zero at the same time. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'common')
-rw-r--r--common/cmd_bootm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index e2cb6b93cd..c533c00d66 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -625,7 +625,7 @@ do_bootm_linux (cmd_tbl_t *cmdtp, int flag,
/* Look for a '-' which indicates to ignore the ramdisk argument */
if (argc >= 3 && strcmp(argv[2], "-") == 0) {
debug ("Skipping initrd\n");
- data = 0;
+ len = data = 0;
}
else
#endif
OpenPOWER on IntegriCloud