Mercurial > emacs
changeset 30030:94dcb1b07998
(get_keyelt): Temporarily inhibit GC while evaluating
a menu filter.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Tue, 04 Jul 2000 12:07:36 +0000 |
parents | 6742ca2adb2b |
children | e3a7a827d1b0 |
files | src/keymap.c |
diffstat | 1 files changed, 5 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/keymap.c Tue Jul 04 11:27:14 2000 +0000 +++ b/src/keymap.c Tue Jul 04 12:07:36 2000 +0000 @@ -592,14 +592,18 @@ /* If there's a `:filter FILTER', apply FILTER to the menu-item's definition to get the real definition to - use. */ + use. Temporarily inhibit GC while evaluating FILTER, + because not functions calling get_keyelt are prepared + for a GC. */ for (; CONSP (tem) && CONSP (XCDR (tem)); tem = XCDR (tem)) if (EQ (XCAR (tem), QCfilter)) { + int count = inhibit_garbage_collection (); Lisp_Object filter; filter = XCAR (XCDR (tem)); filter = list2 (filter, list2 (Qquote, object)); object = menu_item_eval_property (filter); + unbind_to (count, Qnil); break; } }