summaryrefslogtreecommitdiff
path: root/src/quickfix.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2012-01-10 17:13:52 +0100
committerBram Moolenaar <Bram@vim.org>2012-01-10 17:13:52 +0100
commita0f299b4e8dccc2f22ada363a7e293b146c1ece7 (patch)
treee516220c80eff85befd697668630b6e9be27053e /src/quickfix.c
parent10b7b39b3d5bc22d6798cd69fd01c4471669980a (diff)
downloadvim-git-a0f299b4e8dccc2f22ada363a7e293b146c1ece7.tar.gz
updated for version 7.3.398v7.3.398
Problem: When creating more than 10 location lists and adding items one by one a previous location may be used. (Audrius Kažukauskas) Solution: Clear the location list completely when adding the tenth one.
Diffstat (limited to 'src/quickfix.c')
-rw-r--r--src/quickfix.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/quickfix.c b/src/quickfix.c
index 794c49380..26eac7be5 100644
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -899,8 +899,7 @@ qf_new_list(qi, qf_title)
}
else
qi->qf_curlist = qi->qf_listcount++;
- qi->qf_lists[qi->qf_curlist].qf_index = 0;
- qi->qf_lists[qi->qf_curlist].qf_count = 0;
+ vim_memset(&qi->qf_lists[qi->qf_curlist], 0, (size_t)(sizeof(qf_list_T)));
if (qf_title != NULL)
{
char_u *p = alloc((int)STRLEN(qf_title) + 2);
@@ -909,8 +908,6 @@ qf_new_list(qi, qf_title)
if (p != NULL)
sprintf((char *)p, ":%s", (char *)qf_title);
}
- else
- qi->qf_lists[qi->qf_curlist].qf_title = NULL;
}
/*