0
0
mirror of https://github.com/vim/vim.git synced 2025-09-24 03:44:06 -04:00

patch 8.0.0728: the terminal structure is never freed

Problem:    The terminal structure is never freed.
Solution:   Free the structure and unreference what it contains.
This commit is contained in:
Bram Moolenaar
2017-07-17 23:20:24 +02:00
parent 60d0e97497
commit 96ca27a0ee
7 changed files with 73 additions and 18 deletions

View File

@@ -859,6 +859,9 @@ free_buffer(buf_T *buf)
#ifdef FEAT_JOB_CHANNEL
channel_buffer_free(buf);
#endif
#ifdef FEAT_TERMINAL
free_terminal(buf->b_term);
#endif
buf_hashtab_remove(buf);
@@ -1771,7 +1774,7 @@ enter_buffer(buf_T *buf)
#endif
#ifdef FEAT_SYN_HL
curwin->w_s = &(buf->b_s);
curwin->w_s = &(curbuf->b_s);
#endif
/* Cursor on first line by default. */