From 6f72d9b3ed9adee1c766992c0119c3d28a9391a7 Mon Sep 17 00:00:00 2001 From: Masahiro Yamada Date: Tue, 17 Dec 2019 13:14:16 +0900 Subject: [PATCH] kconfig: remove the rootmenu check in menu_add_prop() This reverts commit ba6ff60d5eb4 ("kconfig: don't emit warning upon rootmenu's prompt redefinition"). At that time, rootmenu.prompt was always set first, then it was set again if a "mainmenu" statement was specified in the Kconfig file. This is no longer the case since commit 0724a7c32a54 ("kconfig: Don't leak main menus during parsing"). Remove the unneeded check. Signed-off-by: Masahiro Yamada Signed-off-by: Christian Lamparter --- config/menu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/menu.c b/config/menu.c index d9d1646..b1b1ee8 100644 --- a/config/menu.c +++ b/config/menu.c @@ -138,7 +138,7 @@ static struct property *menu_add_prop(enum prop_type type, char *prompt, struct while (isspace(*prompt)) prompt++; } - if (current_entry->prompt && current_entry != &rootmenu) + if (current_entry->prompt) prop_warn(prop, "prompt redefined"); /* Apply all upper menus' visibilities to actual prompts. */ -- 2.31.1