]> git.eshelyaron.com Git - emacs.git/commitdiff
bibtex-mode: do not fail when local variables are disabled
authorRoland Winkler <winkler@gnu.org>
Wed, 2 Dec 2020 19:51:35 +0000 (13:51 -0600)
committerRoland Winkler <winkler@gnu.org>
Wed, 2 Dec 2020 19:51:35 +0000 (13:51 -0600)
* lisp/textmodes/bibtex.el (bibtex-mode): Check if
enable-local-variables is non-nil (bug#37957).

lisp/textmodes/bibtex.el

index a6c5f637f33319a7c8d3d7305e2b693deb5c70c5..38fea32d2e90ae7a57947ae060899c8f50eb0264 100644 (file)
@@ -3483,7 +3483,7 @@ if that value is non-nil.
                     (make-string (+ bibtex-entry-offset
                                     bibtex-contline-indentation)
                                  ?\s)))))
-    (if buffer-file-name
+    (if (and buffer-file-name enable-local-variables)
         (add-hook 'hack-local-variables-hook fun nil t)
       (funcall fun))))