summaryrefslogtreecommitdiff
path: root/src/buffer.cc
diff options
context:
space:
mode:
authorMaxime Coste <frrrwww@gmail.com>2013-04-29 14:25:38 +0200
committerMaxime Coste <frrrwww@gmail.com>2013-04-29 14:25:38 +0200
commitbef48b7df0cfa8114cc2759612eff55ab0062c4c (patch)
treeac80ca5a99ac06d5d8bf535fcb71e9d0db765013 /src/buffer.cc
parent11bc24f992244b01859ce1dc532d983d96fbb328 (diff)
Fix UndoGroupOptimizer
Diffstat (limited to 'src/buffer.cc')
-rw-r--r--src/buffer.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/buffer.cc b/src/buffer.cc
index 7c5e3d88..068bf55f 100644
--- a/src/buffer.cc
+++ b/src/buffer.cc
@@ -302,7 +302,7 @@ class UndoGroupOptimizer
coord.line -= next_end.line - next_coord.line;
}
}
- else if (it->type == Erase and next_end > coord)
+ else if (it->type == Erase and next_end >= coord)
{
ByteCount start = count_byte_to(next_coord, coord, it_next->content);
it_next->content = it_next->content.substr(0, start) + it->content + it_next->content.substr(start);