mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-06-14 12:31:25 +00:00
Avoid segfaults in TTY menu-item selection
* src/term.c (tty_menu_show): Don't allow "selection" of items in a bogus menu. (Bug#80603)
This commit is contained in:
parent
f59181008f
commit
bb0b9635f9
1 changed files with 3 additions and 0 deletions
|
|
@ -4079,6 +4079,9 @@ tty_menu_show (struct frame *f, int x, int y, int menuflags,
|
|||
status = tty_menu_activate (menu, &pane, &selidx, x, y, &datap,
|
||||
tty_menu_help_callback,
|
||||
menuflags & MENU_KBD_NAVIGATION);
|
||||
if (status == TTYM_SUCCESS && !VECTORP (menu_items))
|
||||
status = TTYM_IA_SELECT;
|
||||
|
||||
entry = pane_prefix = Qnil;
|
||||
|
||||
switch (status)
|
||||
|
|
|
|||
Loading…
Reference in a new issue