Simplify menu_list_new

This commit is contained in:
twinaphex 2015-06-12 14:44:25 +02:00
parent 225c6fac1b
commit 84b8a250a3

View File

@ -191,12 +191,7 @@ menu_list_t *menu_list_new(void)
return list;
error:
if (list->menu_stack)
free(list->menu_stack);
list->menu_stack = NULL;
if (list->selection_buf)
free(list->selection_buf);
list->selection_buf = NULL;
menu_list_free(list);
free(list);
return NULL;
}