mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
API: Bugfix: Check that error isn't set in buffer_get_line
This commit is contained in:
parent
7ce2d63fef
commit
28eb3796b9
@ -56,7 +56,7 @@ String buffer_get_line(Buffer buffer, Integer index, Error *err)
|
||||
String rv = {.size = 0};
|
||||
StringArray slice = buffer_get_slice(buffer, index, index, true, true, err);
|
||||
|
||||
if (slice.size) {
|
||||
if (!err->set && slice.size) {
|
||||
rv = slice.items[0];
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user