api: buffer_insert: fix bounds. #3315

buffer_insert calls buffer_set_line_slice excluding the start
line number and including the end, but it should be the opposite.

Closes https://github.com/neovim/neovim/issues/3212
Closes https://github.com/neovim/python-client/issues/103
This commit is contained in:
Enrico Ghirardi 2015-09-08 20:31:34 +02:00 committed by Justin M. Keyes
parent 3736a613e8
commit 1d1963e90e

View File

@ -467,7 +467,7 @@ void buffer_insert(Buffer buffer,
ArrayOf(String) lines,
Error *err)
{
buffer_set_line_slice(buffer, lnum, lnum, false, true, lines, err);
buffer_set_line_slice(buffer, lnum, lnum, true, false, lines, err);
}
/// Return a tuple (row,col) representing the position of the named mark