From 8dbe47a4bc823e05afed8048e548a5ff9cc1819f Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Wed, 17 Nov 2021 07:07:15 +0800 Subject: vim-patch:8.2.3572: memory leak when closing window and using "multispace" Problem: Memory leak when closing window and using "multispace" in 'listchars'. Solution: Free the memory. (closes vim/vim#9071) https://github.com/vim/vim/commit/7a33ebfc5b04353aa7674972087d581def8fdcc1 --- src/nvim/window.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/nvim/window.c') diff --git a/src/nvim/window.c b/src/nvim/window.c index 59079584ca..26f483c842 100644 --- a/src/nvim/window.c +++ b/src/nvim/window.c @@ -4750,6 +4750,8 @@ static void win_free(win_T *wp, tabpage_T *tp) clear_winopt(&wp->w_onebuf_opt); clear_winopt(&wp->w_allbuf_opt); + xfree(wp->w_p_lcs_chars.multispace); + vars_clear(&wp->w_vars->dv_hashtab); // free all w: variables hash_init(&wp->w_vars->dv_hashtab); unref_var_dict(wp->w_vars); -- cgit