diff options
| author | Maxime Coste <frrrwww@gmail.com> | 2013-06-03 19:01:07 +0200 |
|---|---|---|
| committer | Maxime Coste <frrrwww@gmail.com> | 2013-06-04 14:21:07 +0200 |
| commit | fb41e1fdf9a08bcf869cf9b4e3a4325cdfb18056 (patch) | |
| tree | 728324c491a1b64c42d3b163bf9c23da0d3bd91c /src/buffer.cc | |
| parent | 4ef1bfa4db03526f670213f29ed88212913be43f (diff) | |
tweak Buffer::do_insert
Diffstat (limited to 'src/buffer.cc')
| -rw-r--r-- | src/buffer.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/buffer.cc b/src/buffer.cc index 4738cc47..e0c4c3ff 100644 --- a/src/buffer.cc +++ b/src/buffer.cc @@ -475,7 +475,7 @@ void Buffer::do_insert(const BufferCoord& pos, const String& content) m_lines.push_back({ offset + start, content.substr(start) }); begin = pos.column == 0 ? pos : BufferCoord{ pos.line + 1, 0 }; - end = this->end().coord(); + end = BufferCoord{ line_count()-1, m_lines.back().length() }; } else { |
