forked from aniani/vim
patch 9.0.0368: old Coverity warning for using NULL pointer
Problem: Old Coverity warning for using NULL pointer. Solution: Bail out if dictionary allocation fails.
This commit is contained in:
@@ -4384,7 +4384,11 @@ get_tags(list_T *list, char_u *pat, char_u *buf_fname)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ((dict = dict_alloc()) == NULL)
|
if ((dict = dict_alloc()) == NULL)
|
||||||
|
{
|
||||||
ret = FAIL;
|
ret = FAIL;
|
||||||
|
vim_free(matches[i]);
|
||||||
|
break;
|
||||||
|
}
|
||||||
if (list_append_dict(list, dict) == FAIL)
|
if (list_append_dict(list, dict) == FAIL)
|
||||||
ret = FAIL;
|
ret = FAIL;
|
||||||
|
|
||||||
|
@@ -707,6 +707,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
368,
|
||||||
/**/
|
/**/
|
||||||
367,
|
367,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user