fix(terminal): assign channel to terminal earlier (#25771)

This commit is contained in:
zeertzjq
2023-10-25 09:59:02 +08:00
committed by GitHub
parent 1094d0c0db
commit 684e93054b
6 changed files with 111 additions and 16 deletions

View File

@@ -8637,8 +8637,10 @@ static void f_termopen(typval_T *argvars, typval_T *rettv, EvalFuncData fptr)
INTEGER_OBJ(pid), false, false, &err);
api_clear_error(&err);
channel_incref(chan);
channel_terminal_open(curbuf, chan);
channel_create_event(chan, NULL);
channel_decref(chan);
}
/// "timer_info([timer])" function