emacs-orgmode
[Top][All Lists]
Advanced

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

[PATCH v2 27/38] Fix org-fold--hide-drawers--overlays---


From: Ihor Radchenko
Subject: [PATCH v2 27/38] Fix org-fold--hide-drawers--overlays---
Date: Wed, 20 Apr 2022 21:27:35 +0800

---
 lisp/org-fold.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/org-fold.el b/lisp/org-fold.el
index e48a528bf..a16ee0f9b 100644
--- a/lisp/org-fold.el
+++ b/lisp/org-fold.el
@@ -714,7 +714,7 @@ (defun org-fold--hide-drawers--overlays (begin end)
   "Hide all drawers between BEGIN and END."
   (save-excursion
     (goto-char begin)
-    (while (re-search-forward org-drawer-regexp end t)
+    (while (and (< (point) end) (re-search-forward org-drawer-regexp end t))
       (let* ((pair (get-char-property-and-overlay (line-beginning-position)
                                                   'invisible))
              (o (cdr-safe pair)))
-- 
2.35.1



-- 
Ihor Radchenko,
PhD,
Center for Advancing Materials Performance from the Nanoscale (CAMP-nano)
State Key Laboratory for Mechanical Behavior of Materials, Xi'an Jiaotong 
University, Xi'an, China
Email: yantar92@gmail.com, ihor_radchenko@alumni.sutd.edu.sg



reply via email to

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