emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/org e36a4fe20e 2/2: org-html-final-function: Suppress m


From: ELPA Syncer
Subject: [elpa] externals/org e36a4fe20e 2/2: org-html-final-function: Suppress mode hooks when indenting
Date: Sat, 11 May 2024 06:58:41 -0400 (EDT)

branch: externals/org
commit e36a4fe20e9f39af4f987d0dc5ffe969b8da2eca
Author: Ihor Radchenko <yantar92@posteo.net>
Commit: Ihor Radchenko <yantar92@posteo.net>

    org-html-final-function: Suppress mode hooks when indenting
    
    * lisp/ox-html.el (org-html-final-function): When setting indentation,
    use defaults, suppressing major mode hook.  If we do not, all kinds of
    user code may be executed.
    
    This fix will only work starting from Emacs 30, after bug#70671 is
    fixed:
    https://debbugs.gnu.org/cgi/bugreport.cgi?bug=70671
    
    Reported-by: arozbiz@gmail.com
    Link: https://orgmode.org/list/87tu21hsuk.fsf@localhost
---
 lisp/ox-html.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/ox-html.el b/lisp/ox-html.el
index 5030289456..ec0add65e0 100644
--- a/lisp/ox-html.el
+++ b/lisp/ox-html.el
@@ -3967,7 +3967,7 @@ contextual information."
 CONTENTS is the exported HTML code.  INFO is the info plist."
   (with-temp-buffer
     (insert contents)
-    (set-auto-mode t)
+    (delay-mode-hooks (set-auto-mode t))
     (when (plist-get info :html-indent)
       (indent-region (point-min) (point-max)))
     (buffer-substring-no-properties (point-min) (point-max))))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]