forked from mirrors/org-mode
org-export-with-buffer-copy: Avoid all the hooks, not just `org-mode-hook'
* lisp/ox.el (org-export--generate-copy-script): Use `delay-mode-hooks' to disable all the hooks to be executed instead of only `org-mode-hook'. Reported-by: Rudolf Adamkovič <salutis@me.com> Link: https://list.orgmode.org/m2zgef774u.fsf@me.com/T/#t
This commit is contained in:
parent
5a167f6ef2
commit
aa90e5b59c
|
@ -2622,9 +2622,10 @@ The function assumes BUFFER's major mode is `org-mode'."
|
|||
ov-set)))
|
||||
(lambda ()
|
||||
(let ((inhibit-modification-hooks t))
|
||||
;; Set major mode. Ignore `org-mode-hook' as it has been run
|
||||
;; already in BUFFER.
|
||||
(let ((org-mode-hook nil) (org-inhibit-startup t)) (org-mode))
|
||||
;; Set major mode. Ignore `org-mode-hook' and other hooks as
|
||||
;; they have been run already in BUFFER.
|
||||
(delay-mode-hooks
|
||||
(let ((org-inhibit-startup t)) (org-mode)))
|
||||
;; Copy specific buffer local variables and variables set
|
||||
;; through BIND keywords.
|
||||
(pcase-dolist (`(,var . ,val) varvals)
|
||||
|
|
Loading…
Reference in New Issue