aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/textprop.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/textprop.c b/src/textprop.c
index c4e49d98ebc..aabd5671e76 100644
--- a/src/textprop.c
+++ b/src/textprop.c
@@ -2065,9 +2065,14 @@ extend_property_ranges (Lisp_Object list, Lisp_Object new_end)
2065 else 2065 else
2066 XSETCDR (prev, XCDR (list)); 2066 XSETCDR (prev, XCDR (list));
2067 } 2067 }
2068 else if (XINT (end) > max) 2068 else if (XINT (end) != max)
2069 /* The end-point is past the end of the new string. */ 2069 {
2070 XSETCAR (XCDR (item), new_end); 2070 /* Either the end-point is past the end of the new string,
2071 and we need to discard the properties past the new end,
2072 or the caller is extending the property range, and we
2073 should update the end-point to reflect that. */
2074 XSETCAR (XCDR (item), new_end);
2075 }
2071 } 2076 }
2072 2077
2073 return head; 2078 return head;