diff options
author | Thiago de Arruda <tpadilha84@gmail.com> | 2015-08-12 19:16:06 -0300 |
---|---|---|
committer | Thiago de Arruda <tpadilha84@gmail.com> | 2015-08-13 08:52:17 -0300 |
commit | 6b3cd381dcd01268479dc56103498a029133644d (patch) | |
tree | 0944a99a09ca4c574d4a3945e9bcb9d4f0e8d505 /src/nvim/os/shell.c | |
parent | 166d8c799f367e64744cef4d9a6ddd386809ece8 (diff) | |
download | rneovim-6b3cd381dcd01268479dc56103498a029133644d.tar.gz rneovim-6b3cd381dcd01268479dc56103498a029133644d.tar.bz2 rneovim-6b3cd381dcd01268479dc56103498a029133644d.zip |
rstream: Pass read count to read events
This is necessary to keep events in the same order received from the OS.
Diffstat (limited to 'src/nvim/os/shell.c')
-rw-r--r-- | src/nvim/os/shell.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/nvim/os/shell.c b/src/nvim/os/shell.c index 8faa46dd63..77750bb077 100644 --- a/src/nvim/os/shell.c +++ b/src/nvim/os/shell.c @@ -298,7 +298,8 @@ static void dynamic_buffer_ensure(DynamicBuffer *buf, size_t desired) buf->data = xrealloc(buf->data, buf->cap); } -static void system_data_cb(Stream *stream, RBuffer *buf, void *data, bool eof) +static void system_data_cb(Stream *stream, RBuffer *buf, size_t count, + void *data, bool eof) { DynamicBuffer *dbuf = data; @@ -308,7 +309,8 @@ static void system_data_cb(Stream *stream, RBuffer *buf, void *data, bool eof) dbuf->len += nread; } -static void out_data_cb(Stream *stream, RBuffer *buf, void *data, bool eof) +static void out_data_cb(Stream *stream, RBuffer *buf, size_t count, void *data, + bool eof) { size_t cnt; char *ptr = rbuffer_read_ptr(buf, &cnt); |