# HG changeset patch # User Bram Moolenaar # Date 1583958664 -3600 # Node ID dd3e5533a7d2e97df134324be875f8399af05a3d # Parent 182d7acd67372d206143798e2758f1e8abfa1138 patch 8.2.0373: type of term_sendkeys() is unknown Commit: https://github.com/vim/vim/commit/3a05ce63feae040cd817be289e84c2a7e653d59d Author: Bram Moolenaar Date: Wed Mar 11 19:30:01 2020 +0100 patch 8.2.0373: type of term_sendkeys() is unknown Problem: Type of term_sendkeys() is unknown. Solution: Just return zero. (closes https://github.com/vim/vim/issues/5762) diff --git a/src/terminal.c b/src/terminal.c --- a/src/terminal.c +++ b/src/terminal.c @@ -5746,13 +5746,12 @@ f_term_scrape(typval_T *argvars, typval_ * "term_sendkeys(buf, keys)" function */ void -f_term_sendkeys(typval_T *argvars, typval_T *rettv) +f_term_sendkeys(typval_T *argvars, typval_T *rettv UNUSED) { buf_T *buf = term_get_buf(argvars, "term_sendkeys()"); char_u *msg; term_T *term; - rettv->v_type = VAR_UNKNOWN; if (buf == NULL) return; diff --git a/src/testdir/test_terminal.vim b/src/testdir/test_terminal.vim --- a/src/testdir/test_terminal.vim +++ b/src/testdir/test_terminal.vim @@ -368,7 +368,11 @@ func Test_terminal_postponed_scrollback( call term_wait(buf) call term_sendkeys(buf, "exit\") call term_wait(buf) - call term_sendkeys(buf, ":q\") + let tsk_ret = term_sendkeys(buf, ":q\") + + " check type of term_sendkeys() return value + echo type(tsk_ret) + call StopVimInTerminal(buf) call delete('XTest_postponed') call delete('Xtext') diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -739,6 +739,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 373, +/**/ 372, /**/ 371,