Fix invalid menu items
This commit is contained in:
parent
f2cc401100
commit
3e4e95d9c3
3
menus.c
3
menus.c
@ -105,6 +105,7 @@ int menu_system(char *menufile) {
|
|||||||
}
|
}
|
||||||
menu[menu_items-1] = (struct menu_item *)malloc(sizeof(struct menu_item));
|
menu[menu_items-1] = (struct menu_item *)malloc(sizeof(struct menu_item));
|
||||||
menu[menu_items-1]->hotkey = buffer[7];
|
menu[menu_items-1]->hotkey = buffer[7];
|
||||||
|
menu[menu_items-1]->command = 0;
|
||||||
menu[menu_items-1]->data = NULL;
|
menu[menu_items-1]->data = NULL;
|
||||||
menu[menu_items-1]->seclevel = 0;
|
menu[menu_items-1]->seclevel = 0;
|
||||||
} else if (strncasecmp(buffer, "COMMAND", 7) == 0 && menu_items > 0) {
|
} else if (strncasecmp(buffer, "COMMAND", 7) == 0 && menu_items > 0) {
|
||||||
@ -458,6 +459,8 @@ int menu_system(char *menufile) {
|
|||||||
case MENU_SENDNODEMSG:
|
case MENU_SENDNODEMSG:
|
||||||
send_node_msg();
|
send_node_msg();
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user