]> git.hungrycats.org Git - linux/commitdiff
[PATCH] menu structure fix
authorRoman Zippel <zippel@linux-m68k.org>
Sat, 15 Mar 2003 09:17:12 +0000 (01:17 -0800)
committerLinus Torvalds <torvalds@home.transmeta.com>
Sat, 15 Mar 2003 09:17:12 +0000 (01:17 -0800)
A menu entry was possibly inserted to high in the menu hierarchie if
the previous entry was a derived config symbol.

scripts/kconfig/menu.c

index abfe8d72fbfefe8e7fb8868e8f8defb7a4c0ffd3..81d764e7230d1efe339e990b2cb246bbc9c5d830 100644 (file)
@@ -194,8 +194,8 @@ void menu_finalize(struct menu *parent)
                }
                for (menu = parent->list; menu; menu = menu->next)
                        menu_finalize(menu);
-       } else if (sym && parent->prompt) {
-               basedep = E_EXPR(parent->prompt->visible);
+       } else if (sym) {
+               basedep = parent->prompt ? E_EXPR(parent->prompt->visible) : NULL;
                basedep = expr_trans_compare(basedep, E_UNEQUAL, &symbol_no);
                basedep = expr_eliminate_dups(expr_transform(basedep));
                last_menu = NULL;