summaryrefslogtreecommitdiff
path: root/lisp/facemenu.el
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>2006-10-18 10:51:00 +0000
committerRichard M. Stallman <rms@gnu.org>2006-10-18 10:51:00 +0000
commitf3359de125a632540521967d2d5318ef68efba5e (patch)
tree1c3a2749a0f187a08b96c6be2fc39fc5825f49a1 /lisp/facemenu.el
parentec9581d515d2aa4073738e2e057464fc73acd825 (diff)
downloademacs-f3359de125a632540521967d2d5318ef68efba5e.tar.gz
emacs-f3359de125a632540521967d2d5318ef68efba5e.tar.bz2
emacs-f3359de125a632540521967d2d5318ef68efba5e.zip
(facemenu-add-new-face): Defend against symbol that isn't a face name.
Diffstat (limited to 'lisp/facemenu.el')
-rw-r--r--lisp/facemenu.el3
1 files changed, 3 insertions, 0 deletions
diff --git a/lisp/facemenu.el b/lisp/facemenu.el
index eaaf4dacd72..13cf7fbd734 100644
--- a/lisp/facemenu.el
+++ b/lisp/facemenu.el
@@ -690,6 +690,9 @@ This is called whenever you create a new face, and at other times."
(cond ((facemenu-iterate ; check if equivalent face is already in the menu
(lambda (m) (and (listp m)
(symbolp (car m))
+ ;; Avoid error in face-equal
+ ;; when a non-face is erroneously present.
+ (facep (car m))
(face-equal (car m) symbol)))
(cdr (symbol-function menu))))
;; Faces with a keyboard equivalent. These go at the front.