diff options
Diffstat (limited to 'src/nvim/term.c')
-rw-r--r-- | src/nvim/term.c | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/src/nvim/term.c b/src/nvim/term.c index 1169435a4f..b7c30300b0 100644 --- a/src/nvim/term.c +++ b/src/nvim/term.c @@ -170,7 +170,6 @@ static struct builtin_term builtin_termcaps[] = {(int)KS_DL, "\033|d"}, {(int)KS_CDL, "\033|%p1%dD"}, {(int)KS_CS, "\033|%p1%d;%p2%dR"}, - {(int)KS_CSV, "\033|%p1%d;%p2%dV"}, {(int)KS_CL, "\033|C"}, // attributes switched on with 'h', off with * 'H' {(int)KS_ME, "\033|31H"}, // HL_ALL @@ -1818,20 +1817,17 @@ void term_write(char_u *s, size_t len) static char_u out_buf[OUT_SIZE + 1]; static int out_pos = 0; /* number of chars in out_buf */ -// Clear the output buffer -void out_buf_clear(void) -{ - out_pos = 0; -} - /* * out_flush(): flush the output buffer */ void out_flush(void) { - int len = out_pos; - out_pos = 0; - ui_write(out_buf, len); + if (out_pos != 0) { + /* set out_pos to 0 before ui_write, to avoid recursiveness */ + int len = out_pos; + out_pos = 0; + ui_write(out_buf, len); + } } /* |