diff options
author | Björn Linse <bjorn.linse@gmail.com> | 2016-10-22 12:50:50 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-22 12:50:50 +0200 |
commit | 31df051ed9a3f8cc9ad7a4e408e3ba03a1c5272b (patch) | |
tree | 5e62dbb09dc5d02818d2a080b08af2168f306f8b /src/nvim/api/buffer.c | |
parent | e9041862776715cfb24e29fb7f18fa0830bd5555 (diff) | |
parent | f6968dc0f7775591108aebbfe30e597dd0882c91 (diff) | |
download | rneovim-31df051ed9a3f8cc9ad7a4e408e3ba03a1c5272b.tar.gz rneovim-31df051ed9a3f8cc9ad7a4e408e3ba03a1c5272b.tar.bz2 rneovim-31df051ed9a3f8cc9ad7a4e408e3ba03a1c5272b.zip |
Merge pull request #4568 from bfredl/multirequest
atomic multi request for async remote plugins
Diffstat (limited to 'src/nvim/api/buffer.c')
-rw-r--r-- | src/nvim/api/buffer.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/api/buffer.c b/src/nvim/api/buffer.c index c4415ddf94..09d717bff6 100644 --- a/src/nvim/api/buffer.c +++ b/src/nvim/api/buffer.c @@ -191,7 +191,7 @@ ArrayOf(String) nvim_buf_get_lines(uint64_t channel_id, Object str = STRING_OBJ(cstr_to_string(bufstr)); // Vim represents NULs as NLs, but this may confuse clients. - if (channel_id != INVALID_CHANNEL) { + if (channel_id != INTERNAL_CALL) { strchrsub(str.data.string.data, '\n', '\0'); } @@ -312,7 +312,7 @@ void nvim_buf_set_lines(uint64_t channel_id, // line and convert NULs to newlines to avoid truncation. lines[i] = xmallocz(l.size); for (size_t j = 0; j < l.size; j++) { - if (l.data[j] == '\n' && channel_id != INVALID_CHANNEL) { + if (l.data[j] == '\n' && channel_id != INTERNAL_CALL) { api_set_error(err, Exception, _("string cannot contain newlines")); new_len = i + 1; goto end; |