The empty check in the menu system used "cm", but before "cm" had
actually been initialized. Move the "cm" initialization earlier so we
do the right thing here.
Reported-by: CKSoon <cksoon79@yahoo.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
m->mparm[i] = max(m->mparm[i] + rows, 0);
}
+ cm = start_menu;
+
if (!cm->nentries) {
fputs("Initial menu has no LABEL entries!\n", stdout);
return 1; /* Error! */
}
- cm = start_menu;
for (;;) {
cmdline = run_menu();