mirror of
https://github.com/vim/vim.git
synced 2025-09-27 04:14:06 -04:00
patch 7.4.1597
Problem: Memory leak when out of memory. (Coverity) Solution: Free the name.
This commit is contained in:
@@ -11904,7 +11904,9 @@ f_function(typval_T *argvars, typval_T *rettv)
|
|||||||
partial_T *pt = (partial_T *)alloc_clear(sizeof(partial_T));
|
partial_T *pt = (partial_T *)alloc_clear(sizeof(partial_T));
|
||||||
|
|
||||||
/* result is a VAR_PARTIAL */
|
/* result is a VAR_PARTIAL */
|
||||||
if (pt != NULL)
|
if (pt == NULL)
|
||||||
|
vim_free(name);
|
||||||
|
else
|
||||||
{
|
{
|
||||||
if (arg_idx > 0 || (arg_pt != NULL && arg_pt->pt_argc > 0))
|
if (arg_idx > 0 || (arg_pt != NULL && arg_pt->pt_argc > 0))
|
||||||
{
|
{
|
||||||
|
@@ -748,6 +748,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 */
|
||||||
|
/**/
|
||||||
|
1597,
|
||||||
/**/
|
/**/
|
||||||
1596,
|
1596,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user