feat(remote): avoid --remote-ui infinite loop (#24465)

This commit is contained in:
shafouz
2023-08-13 02:14:08 -04:00
committed by GitHub
parent e551d623d2
commit 7b0123dd6a
2 changed files with 18 additions and 0 deletions

View File

@@ -921,6 +921,11 @@ static void remote_request(mparm_T *params, int remote_args, char *server_addr,
os_errmsg(connect_error);
os_errmsg("\n");
os_exit(1);
} else if (strequal(server_addr, os_getenv("NVIM"))) {
os_errmsg("Cannot attach UI of :terminal child to its parent. ");
os_errmsg("(Unset $NVIM to skip this check)");
os_errmsg("\n");
os_exit(1);
}
ui_client_channel_id = chan;