diff options
author | Thiago de Arruda <tpadilha84@gmail.com> | 2014-08-28 17:01:58 -0300 |
---|---|---|
committer | Thiago de Arruda <tpadilha84@gmail.com> | 2014-08-29 22:08:58 -0300 |
commit | a66d2d15382fb153bfa860c0b3ea7cb9630c8afa (patch) | |
tree | 6790fb6db9b1cccf006dacb4df175a28eb1dea6f /src/nvim/os/provider.c | |
parent | aa23d2f835e32c01b318712459ba7b9f55922469 (diff) | |
download | rneovim-a66d2d15382fb153bfa860c0b3ea7cb9630c8afa.tar.gz rneovim-a66d2d15382fb153bfa860c0b3ea7cb9630c8afa.tar.bz2 rneovim-a66d2d15382fb153bfa860c0b3ea7cb9630c8afa.zip |
msgpack-rpc: Always use arrays when sending events or calls
This is required by the msgpack-RPC specification. Also, the
send_call/send_event functions were refactored to accept a variable number of
arguments
Diffstat (limited to 'src/nvim/os/provider.c')
-rw-r--r-- | src/nvim/os/provider.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/os/provider.c b/src/nvim/os/provider.c index d94203f683..07e757fe0e 100644 --- a/src/nvim/os/provider.c +++ b/src/nvim/os/provider.c @@ -98,7 +98,7 @@ bool provider_register(char *method, uint64_t channel_id) return true; } -Object provider_call(char *method, Object arg) +Object provider_call(char *method, Array args) { uint64_t channel_id = get_provider_for(method); @@ -109,13 +109,13 @@ Object provider_call(char *method, Object arg) "Provider for \"%s\" is not available", method); report_error(buf); - msgpack_rpc_free_object(arg); + msgpack_rpc_free_array(args); return NIL; } bool error = false; Object result = NIL; - channel_send_call(channel_id, method, arg, &result, &error); + channel_send_call(channel_id, method, args, &result, &error); if (error) { report_error(result.data.string.data); |