]> git.eshelyaron.com Git - emacs.git/commit
Fix keyboard.c infloops on circular lists
authorPaul Eggert <eggert@cs.ucla.edu>
Wed, 30 Oct 2019 21:24:29 +0000 (14:24 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Wed, 30 Oct 2019 21:43:14 +0000 (14:43 -0700)
commit581601e650cc8bdcf3ed83c6ae36744601c12ce9
tree37cc3bd330820866ff9d3aa2bf37e2fd84725739
parent40ae02ff50a8f05660a7f9f234320875b6358c9d
Fix keyboard.c infloops on circular lists

Fix infinite loops in keyboard.c when a circular list is
found in a hook, or in help-event-list, or in the argument
of event-convert-list, or in a keymap where a Lucid event
type list is expected, or in a menu or tab spec.
* src/keyboard.c (safe_run_hooks_error, menu_bar_items)
(parse_menu_item, parse_tab_bar_item, parse_tool_bar_item):
Use FOR_EACH_TAIL to avoid infloop on circular lists.
(help_char_p, Fevent_convert_list, lucid_event_type_list_p):
Use FOR_EACH_TAIL_SAFE to avoid infloop on circular lists,
when the action is idempotent so a circular list can be
treated as a noncircular one.
src/keyboard.c