]> git.eshelyaron.com Git - emacs.git/commitdiff
* src/editfns.c (Fget_pos_property): Fix thinko (bug#69358)
authorStefan Monnier <monnier@iro.umontreal.ca>
Sat, 24 Feb 2024 17:23:41 +0000 (12:23 -0500)
committerEshel Yaron <me@eshelyaron.com>
Wed, 28 Feb 2024 17:52:09 +0000 (18:52 +0100)
(cherry picked from commit 56beeff14365d8e802ab7b4888aa7e95b2cf9509)

src/editfns.c

index cce52cddbf873a36d464302288b3833c928a7200..4ccf765bd4bc29d1c9a4543bf5ef21506caff629 100644 (file)
@@ -301,8 +301,8 @@ at POSITION.  */)
       struct buffer *obuf = current_buffer;
       struct itree_node *node;
       struct sortvec items[2];
-      struct sortvec *result = NULL;
       struct buffer *b = XBUFFER (object);
+      struct sortvec *result = NULL;
       Lisp_Object res = Qnil;
 
       set_buffer_temp (b);
@@ -326,7 +326,10 @@ at POSITION.  */)
           if (NILP (res)
               || (make_sortvec_item (this, node->data),
                   compare_overlays (result, this) < 0))
-            res = tem;
+            {
+              result = this;
+              res = tem;
+            }
        }
       set_buffer_temp (obuf);