aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJames McCoy <jamessan@jamessan.com>2016-12-12 15:05:58 -0500
committerJames McCoy <jamessan@jamessan.com>2016-12-27 14:10:27 -0500
commitfd94e6313b3e7314561cbe90b4cacd44d1088c8f (patch)
tree79d512b6ec2966b87b3fd27d4a3ae6d03bb74726 /src
parent82f54c0a5eea91dcfd7a509588b4ac37f7e55b57 (diff)
downloadrneovim-fd94e6313b3e7314561cbe90b4cacd44d1088c8f.tar.gz
rneovim-fd94e6313b3e7314561cbe90b4cacd44d1088c8f.tar.bz2
rneovim-fd94e6313b3e7314561cbe90b4cacd44d1088c8f.zip
vim-patch:7.4.1966
Problem: Coverity reports a resource leak. Solution: Close "fd" also when bailing out. https://github.com/vim/vim/commit/bcf7772a23624edc0942120e564f6b4ac95604ad
Diffstat (limited to 'src')
-rw-r--r--src/nvim/quickfix.c5
-rw-r--r--src/nvim/version.c2
2 files changed, 3 insertions, 4 deletions
diff --git a/src/nvim/quickfix.c b/src/nvim/quickfix.c
index 1499c3e12f..39f95d19ae 100644
--- a/src/nvim/quickfix.c
+++ b/src/nvim/quickfix.c
@@ -941,7 +941,7 @@ restofline:
}
/* return number of matches */
retval = qi->qf_lists[qi->qf_curlist].qf_count;
- goto qf_init_ok;
+ goto qf_init_end;
}
EMSG(_(e_readerrf));
error2:
@@ -949,13 +949,12 @@ error2:
qi->qf_listcount--;
if (qi->qf_curlist > 0)
--qi->qf_curlist;
-qf_init_ok:
+qf_init_end:
if (fd != NULL)
fclose(fd);
free_efm_list(&fmt_first);
qf_clean_dir_stack(&dir_stack);
qf_clean_dir_stack(&file_stack);
-qf_init_end:
xfree(namebuf);
xfree(errmsg);
xfree(pattern);
diff --git a/src/nvim/version.c b/src/nvim/version.c
index 3efc161b05..576843e61d 100644
--- a/src/nvim/version.c
+++ b/src/nvim/version.c
@@ -474,7 +474,7 @@ static int included_patches[] = {
// 1969 NA
// 1968,
1967,
- // 1966,
+ 1966,
// 1965 NA
1964,
// 1963 NA