diff options
| -rw-r--r-- | lisp/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/tmm.el | 10 |
2 files changed, 11 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7a9fae9f412..1bbc73872ab 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2010-04-02 Jan Djärv <jan.h.d@swipnet.se> + + * tmm.el (tmm-get-keymap): Check with symbolp before passing + value to fboundp, it may not be a symbol. + 2010-03-31 Chong Yidong <cyd@stupidchicken.com> * cus-edit.el (custom-buffer-sort-alphabetically): Update diff --git a/lisp/tmm.el b/lisp/tmm.el index f4ae3c110d5..97f017e2352 100644 --- a/lisp/tmm.el +++ b/lisp/tmm.el @@ -452,20 +452,21 @@ It uses the free variable `tmm-table-undef' to keep undefined keys." (unless (assoc event tmm-table-undef) (cond ((if (listp elt) (or (keymapp elt) (eq (car elt) 'lambda)) - (fboundp elt)) + (and (symbolp elt) (fboundp elt))) (setq km elt)) ((if (listp (cdr-safe elt)) (or (keymapp (cdr-safe elt)) (eq (car (cdr-safe elt)) 'lambda)) - (fboundp (cdr-safe elt))) + (and (symbolp (cdr-safe elt)) (fboundp (cdr-safe elt)))) (setq km (cdr elt)) (and (stringp (car elt)) (setq str (car elt)))) ((if (listp (cdr-safe (cdr-safe elt))) (or (keymapp (cdr-safe (cdr-safe elt))) (eq (car (cdr-safe (cdr-safe elt))) 'lambda)) - (fboundp (cdr-safe (cdr-safe elt)))) + (and (symbolp (cdr-safe (cdr-safe elt)) + (fboundp (cdr-safe (cdr-safe elt)))))) (setq km (cddr elt)) (and (stringp (car elt)) (setq str (car elt))) (and str @@ -499,7 +500,8 @@ It uses the free variable `tmm-table-undef' to keep undefined keys." ((if (listp (cdr-safe (cdr-safe (cdr-safe elt)))) (or (keymapp (cdr-safe (cdr-safe (cdr-safe elt)))) (eq (car (cdr-safe (cdr-safe (cdr-safe elt)))) 'lambda)) - (fboundp (cdr-safe (cdr-safe (cdr-safe elt))))) + (and (symbolp (cdr-safe (cdr-safe (cdr-safe elt)))) + (fboundp (cdr-safe (cdr-safe (cdr-safe elt)))))) ; New style of easy-menu (setq km (cdr (cddr elt))) (and (stringp (car elt)) (setq str (car elt))) |
