emacs-diffs
[Top][All Lists]
Advanced

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

master 76f49943c3: Make sure to preserve point across locked narrowing


From: Eli Zaretskii
Subject: master 76f49943c3: Make sure to preserve point across locked narrowing
Date: Sat, 30 Jul 2022 09:12:46 -0400 (EDT)

branch: master
commit 76f49943c3baf1fa342889e08c5b6b86c2736437
Author: Eli Zaretskii <eliz@gnu.org>
Commit: Eli Zaretskii <eliz@gnu.org>

    Make sure to preserve point across locked narrowing
    
    * src/editfns.c (Fnarrow_to_region): Save the position of point
    when locking the restriction, since this function can move point.
---
 src/editfns.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/editfns.c b/src/editfns.c
index d15d4dc68b..79af27d24d 100644
--- a/src/editfns.c
+++ b/src/editfns.c
@@ -2721,6 +2721,7 @@ the current body form.  */)
       if (BEGV != s || ZV != e)
        current_buffer->clip_changed = 1;
 
+      record_unwind_protect (restore_point_unwind, Fpoint_marker ());
       record_unwind_protect (unwind_locked_begv, Fpoint_min ());
       record_unwind_protect (unwind_locked_zv, Fpoint_max ());
 



reply via email to

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