From: Roland Winkler Date: Wed, 2 Dec 2020 19:51:35 +0000 (-0600) Subject: bibtex-mode: do not fail when local variables are disabled X-Git-Tag: emacs-28.0.90~4955 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=40f42945ed1ee76c16ee4c58c7f37a412a3aa407;p=emacs.git bibtex-mode: do not fail when local variables are disabled * lisp/textmodes/bibtex.el (bibtex-mode): Check if enable-local-variables is non-nil (bug#37957). --- diff --git a/lisp/textmodes/bibtex.el b/lisp/textmodes/bibtex.el index a6c5f637f33..38fea32d2e9 100644 --- a/lisp/textmodes/bibtex.el +++ b/lisp/textmodes/bibtex.el @@ -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))))