1
0
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2025-01-05 11:45:52 +00:00

Fix for infinite loop in org-html-protect

When I export the following as HTML, emacs hangs in org-html-protect:

#+begin_src org
&
#+end_src

The attached patch fixes the problem for me.

Thanks,
Kim.
>From cfb1ccb6f9cfd84530c73b7f72d686a2062b3c3b Mon Sep 17 00:00:00 2001
From: Kim Rutherford <kmr44@cam.ac.uk>
Date: Fri, 11 Mar 2011 16:44:09 +0000
Subject: [PATCH] Fix infinite loop in org-html-protect
This commit is contained in:
Kim Rutherford 2011-03-11 22:30:43 +00:00 committed by Bastien Guerry
parent ed8a9616a2
commit 3bf379aee9

View File

@ -2186,7 +2186,7 @@ Possible conversions are set in `org-export-html-protect-char-alist'."
(let ((start 0))
(while (string-match (car c) s start)
(setq s (replace-match (cdr c) t t s)
start (match-beginning 0)))))
start (1+ (match-beginning 0))))))
s))
(defun org-html-expand (string)