9
0
Fork 0

menu: do not go to free if there's nothing to free

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
Sascha Hauer 2010-08-21 19:05:52 +02:00
parent f50d2063cb
commit c0477d8233
1 changed files with 1 additions and 2 deletions

View File

@ -80,9 +80,8 @@ static int do_menu_entry_add(struct cmd_menu *cm)
}
me = menu_entry_alloc();
if (!me)
goto free;
return -ENOMEM;
if (cm->submenu) {
me->action = menu_action_show;