aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2003-11-03 14:44:48 +0000
committerStefan Monnier2003-11-03 14:44:48 +0000
commit552eb607925c30edb27e0ee0aecec6251e02bac1 (patch)
treee5b0e6b59df3c978f9ba24d8a357abe60653653b
parent984002eb3babcf05857256c4e529c878fd9b5f19 (diff)
downloademacs-552eb607925c30edb27e0ee0aecec6251e02bac1.tar.gz
emacs-552eb607925c30edb27e0ee0aecec6251e02bac1.zip
(add-hook): Fix last change.
-rw-r--r--lisp/subr.el4
1 files changed, 1 insertions, 3 deletions
diff --git a/lisp/subr.el b/lisp/subr.el
index e29c48ae743..e0fdc5c0b24 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -856,9 +856,7 @@ function, it is changed to a list of functions."
856 (set (make-local-variable hook) (list t))) 856 (set (make-local-variable hook) (list t)))
857 ;; Detect the case where make-local-variable was used on a hook 857 ;; Detect the case where make-local-variable was used on a hook
858 ;; and do what we used to do. 858 ;; and do what we used to do.
859 (when (and (local-variable-p hook) 859 (unless (and (consp (symbol-value hook)) (memq t (symbol-value hook)))
860 (not (and (consp (symbol-value hook))
861 (memq t (symbol-value hook)))))
862 (setq local t))) 860 (setq local t)))
863 (let ((hook-value (if local (symbol-value hook) (default-value hook)))) 861 (let ((hook-value (if local (symbol-value hook) (default-value hook))))
864 ;; If the hook value is a single function, turn it into a list. 862 ;; If the hook value is a single function, turn it into a list.