mirror of
https://github.com/vim/vim.git
synced 2025-07-26 11:04:33 -04:00
patch 7.4.1867
Problem: Memory leak in test_matchstrpos. Solution: Free the string before overwriting. (Yegappan Lakshmanan)
This commit is contained in:
parent
a96732150c
commit
3c809343c7
@ -15773,6 +15773,7 @@ find_some_match(typval_T *argvars, typval_T *rettv, int type)
|
||||
listitem_T *li3 = li2->li_next;
|
||||
listitem_T *li4 = li3->li_next;
|
||||
|
||||
vim_free(li1->li_tv.vval.v_string);
|
||||
li1->li_tv.vval.v_string = vim_strnsave(regmatch.startp[0],
|
||||
(int)(regmatch.endp[0] - regmatch.startp[0]));
|
||||
li3->li_tv.vval.v_number =
|
||||
|
@ -753,6 +753,8 @@ static char *(features[]) =
|
||||
|
||||
static int included_patches[] =
|
||||
{ /* Add new patch number below this line */
|
||||
/**/
|
||||
1867,
|
||||
/**/
|
||||
1866,
|
||||
/**/
|
||||
|
Loading…
x
Reference in New Issue
Block a user