projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b3e930d
)
* src/intervals.c (set_intervals_multibyte_1): Fix bug#61887
author
Stefan Monnier
<monnier@iro.umontreal.ca>
Sat, 4 Mar 2023 00:13:03 +0000
(19:13 -0500)
committer
Stefan Monnier
<monnier@iro.umontreal.ca>
Sat, 4 Mar 2023 00:13:03 +0000
(19:13 -0500)
When `total_length` is 0 there should be no subtree at all, but
`delete_interval` only deletes one interval, so make sure we don't end
up with some stale child of `i`.
src/intervals.c
patch
|
blob
|
history
diff --git
a/src/intervals.c
b/src/intervals.c
index 75e37a8c90c3a929d700d48d42183b123cda4fc5..ee976fb10352dccfcf66a091e2a48e52c50bd55d 100644
(file)
--- a/
src/intervals.c
+++ b/
src/intervals.c
@@
-2333,6
+2333,9
@@
set_intervals_multibyte_1 (INTERVAL i, bool multi_flag,
if (TOTAL_LENGTH (i) == 0)
{
+ /* Delete the whole subtree. */
+ i->left = NULL;
+ i->right = NULL;
delete_interval (i);
return;
}