Commit bd6b64e0 authored by Juri Linkov's avatar Juri Linkov
Browse files

* lisp/progmodes/project.el: Don't run modes from .dir-locals.el.

(project--value-in-dir): Use 'alist-get' on 'file-local-variables-alist'
to avoid calling 'hack-local-variables-apply' via
'hack-dir-local-variables-non-file-buffer' because it might enable
undesirable modes such as flyspell-mode in a temporary buffer (bug#69740).
parent f3deaa11
Pipeline #28505 failed with stage
in 8 minutes and 52 seconds
......@@ -808,8 +808,9 @@ DIRS must contain directory names."
(with-temp-buffer
(setq default-directory dir)
(let ((enable-local-variables :all))
(hack-dir-local-variables-non-file-buffer))
(symbol-value var)))
(hack-dir-local-variables))
;; Don't use `hack-local-variables-apply' to avoid setting modes.
(alist-get var file-local-variables-alist)))
(cl-defmethod project-buffers ((project (head vc)))
(let* ((root (expand-file-name (file-name-as-directory (project-root project))))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment