aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2019-06-06 20:51:11 -0400
committerJan Edmund Lazo <jan.lazo@mail.utoronto.ca>2019-06-06 22:43:48 -0400
commite653f39f4f93b143ffa379c81cd55deb109fc8d7 (patch)
treeb7f0e0d9b9b8703cc2e8358bfe3156e236de85f1 /src
parentbb4e0deaf924490f792433becbe0629fe0ce5b4e (diff)
downloadrneovim-e653f39f4f93b143ffa379c81cd55deb109fc8d7.tar.gz
rneovim-e653f39f4f93b143ffa379c81cd55deb109fc8d7.tar.bz2
rneovim-e653f39f4f93b143ffa379c81cd55deb109fc8d7.zip
vim-patch:8.0.1702: leaking memory when autocommands make quickfix list invalid
Problem: Leaking memory when autocommands make a quickfix list invalid. Solution: Call FreeWild(). (Yegappan Lakshmanan) https://github.com/vim/vim/commit/ee5b94a8ecbaeafa11c7c7c8cf7bef765fbea912
Diffstat (limited to 'src')
-rw-r--r--src/nvim/quickfix.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/nvim/quickfix.c b/src/nvim/quickfix.c
index 03f909f634..ced0cf0f80 100644
--- a/src/nvim/quickfix.c
+++ b/src/nvim/quickfix.c
@@ -4142,6 +4142,7 @@ void ex_vimgrep(exarg_T *eap)
// Check whether the quickfix list is still valid. When loading a
// buffer above, autocommands might have changed the quickfix list.
if (!vgr_qflist_valid(wp, qi, save_qfid, *eap->cmdlinep)) {
+ FreeWild(fcount, fnames);
goto theend;
}
save_qfid = qi->qf_lists[qi->qf_curlist].qf_id;