aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/msgpack_rpc/channel.c
diff options
context:
space:
mode:
authorbfredl <bjorn.linse@gmail.com>2022-03-12 13:47:50 +0100
committerbfredl <bjorn.linse@gmail.com>2022-03-12 19:24:46 +0100
commita4400bf8cda8ace4c4aab67bc73a1820478f46f1 (patch)
tree1b63176d66c1e09a030499971591cf20c172c390 /src/nvim/msgpack_rpc/channel.c
parent3a12737e6c13e9be774483f34655e7ac96e36c09 (diff)
downloadrneovim-a4400bf8cda8ace4c4aab67bc73a1820478f46f1.tar.gz
rneovim-a4400bf8cda8ace4c4aab67bc73a1820478f46f1.tar.bz2
rneovim-a4400bf8cda8ace4c4aab67bc73a1820478f46f1.zip
feat(ui): connect to remote ui (only debug messages for now)
co-authored-by: hlpr98 <hlpr98@gmail.com>
Diffstat (limited to 'src/nvim/msgpack_rpc/channel.c')
-rw-r--r--src/nvim/msgpack_rpc/channel.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/nvim/msgpack_rpc/channel.c b/src/nvim/msgpack_rpc/channel.c
index 299651ee97..f4e836fa81 100644
--- a/src/nvim/msgpack_rpc/channel.c
+++ b/src/nvim/msgpack_rpc/channel.c
@@ -547,6 +547,11 @@ void rpc_close(Channel *channel)
channel->rpc.closed = true;
channel_decref(channel);
+ if (channel->id == ui_client_channel_id) {
+ // TODO(bfredl): handle this in ui_client, where os_exit() is safe
+ exit(0);
+ }
+
if (channel->streamtype == kChannelStreamStdio) {
multiqueue_put(main_loop.fast_events, exit_event, 0);
}