summaryrefslogtreecommitdiff
path: root/lisp/files.el
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2005-09-12 15:05:24 +0000
committerStefan Monnier <monnier@iro.umontreal.ca>2005-09-12 15:05:24 +0000
commit344f1111500c283c138f3d43deb7572780cf858b (patch)
treec6907559b87faa60f2cbc3e0126b79a5a0debdd6 /lisp/files.el
parentdfc22242b5b96d0344fdadb23e723e2f637af40f (diff)
downloademacs-344f1111500c283c138f3d43deb7572780cf858b.tar.gz
(normal-mode): Check boundness of font-lock-keywords.
Diffstat (limited to 'lisp/files.el')
-rw-r--r--lisp/files.el6
1 files changed, 5 insertions, 1 deletions
diff --git a/lisp/files.el b/lisp/files.el
index 1ffd17eefd4..6356fcb8c2c 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -1738,7 +1738,11 @@ in that case, this function acts as if `enable-local-variables' were t."
(hack-local-variables)))
;; Turn font lock off and on, to make sure it takes account of
;; whatever file local variables are relevant to it.
- (when (and font-lock-mode (eq (car font-lock-keywords) t))
+ (when (and font-lock-mode
+ ;; Font-lock-mode (now in font-core.el) can be ON when
+ ;; font-lock.el still hasn't been loaded.
+ (boundp 'font-lock-keywords)
+ (eq (car font-lock-keywords) t))
(setq font-lock-keywords (cadr font-lock-keywords))
(font-lock-mode 1))