]> git.sur5r.net Git - u-boot/commit
kconfig: Fix warning "‘jump’ may be used uninitialized"
authorPeter Kümmel <syntheticpp@gmx.net>
Sat, 29 Nov 2014 08:26:04 +0000 (17:26 +0900)
committerTom Rini <trini@ti.com>
Mon, 8 Dec 2014 14:35:48 +0000 (09:35 -0500)
commit60cd06e13c32c569a03bb7b4a872b770c2b7813a
treef874a6392c40ef19325e1b8166680378199b64dc
parent61eb5d72abd3d156baf9de2133226dc5d8da3150
kconfig: Fix warning "‘jump’ may be used uninitialized"

Warning:
In file included from scripts/kconfig/zconf.tab.c:2537:0:
scripts/kconfig/menu.c: In function ‘get_symbol_str’:
scripts/kconfig/menu.c:590:18: warning: ‘jump’ may be used uninitialized in this function [-Wmaybe-uninitialized]
     jump->offset = strlen(r->s);

Simplifies the test logic because (head && local) means (jump != 0)
and makes GCC happy when checking if the jump pointer was initialized.

Signed-off-by: Peter Kümmel <syntheticpp@gmx.net>
Signed-off-by: Michal Marek <mmarek@suse.cz>
[ imported from Linux Kernel, commit 2d5603060967 ]
Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
scripts/kconfig/menu.c