diff options
Diffstat (limited to 'src/nvim/eval.c')
-rw-r--r-- | src/nvim/eval.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/nvim/eval.c b/src/nvim/eval.c index 1a690fdf8f..7a8402a6bb 100644 --- a/src/nvim/eval.c +++ b/src/nvim/eval.c @@ -12227,8 +12227,16 @@ static void f_jobstop(typval_T *argvars, typval_T *rettv, FunPtr fptr) return; } + const char *error = NULL; + if (data->is_rpc) { + // Ignore return code, but show error later. + (void)channel_close(data->id, kChannelPartRpc, &error); + } process_stop((Process *)&data->stream.proc); rettv->vval.v_number = 1; + if (error) { + EMSG(error); + } } // "jobwait(ids[, timeout])" function |