summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-01-18 20:30:17 +0100
committerBram Moolenaar <Bram@vim.org>2016-01-18 20:30:17 +0100
commit61ff4dd6a4d47bd32383fe28087be2b37dec53f4 (patch)
treef031401a5fb15a0401aa2ecdd80db3c94a810659
parent77324fc9d3206a12f5ae39da1574be3ee1273591 (diff)
downloadvim-git-61ff4dd6a4d47bd32383fe28087be2b37dec53f4.tar.gz
patch 7.4.1130v7.4.1130
Problem: Memory leak in :vimgrep. Solution: Call FreeWild(). (Yegappan Lakshmanan)
-rw-r--r--src/quickfix.c3
-rw-r--r--src/version.c2
2 files changed, 5 insertions, 0 deletions
diff --git a/src/quickfix.c b/src/quickfix.c
index 003d0075d..21ac1c034 100644
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -3465,7 +3465,10 @@ ex_vimgrep(eap)
dirname_start = alloc_id(MAXPATHL, aid_qf_dirname_start);
dirname_now = alloc_id(MAXPATHL, aid_qf_dirname_now);
if (dirname_start == NULL || dirname_now == NULL)
+ {
+ FreeWild(fcount, fnames);
goto theend;
+ }
/* Remember the current directory, because a BufRead autocommand that does
* ":lcd %:p:h" changes the meaning of short path names. */
diff --git a/src/version.c b/src/version.c
index ed7eddc35..444d4b817 100644
--- a/src/version.c
+++ b/src/version.c
@@ -742,6 +742,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 1130,
+/**/
1129,
/**/
1128,