mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-05 15:15:42 +00:00
PR29261, memory leak in parse_stab_struct_fields
PR 29261 * stabs.c (parse_stab_struct_fields): Free "fields" on failure path.
This commit is contained in:
@@ -2367,7 +2367,10 @@ parse_stab_struct_fields (void *dhandle,
|
|||||||
|
|
||||||
if (! parse_stab_one_struct_field (dhandle, info, pp, p, fields + c,
|
if (! parse_stab_one_struct_field (dhandle, info, pp, p, fields + c,
|
||||||
staticsp, p_end))
|
staticsp, p_end))
|
||||||
return false;
|
{
|
||||||
|
free (fields);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
++c;
|
++c;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user