mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2025-01-06 12:09:26 +08:00
readelf memory leak in process_mips_specific
* readelf.c (process_mips_specific): Free iconf on error path.
This commit is contained in:
parent
1ce0847daa
commit
5a814d6d96
@ -1,3 +1,7 @@
|
||||
2020-03-24 Alan Modra <amodra@gmail.com>
|
||||
|
||||
* readelf.c (process_mips_specific): Free iconf on error path.
|
||||
|
||||
2020-03-23 Nick Clifton <nickc@redhat.com>
|
||||
|
||||
PR 25714
|
||||
|
@ -17074,7 +17074,10 @@ process_mips_specific (Filedata * filedata)
|
||||
get_data (NULL, filedata, conflicts_offset,
|
||||
sizeof (*econf32), conflictsno, _("conflict"));
|
||||
if (!econf32)
|
||||
return FALSE;
|
||||
{
|
||||
free (iconf);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
for (cnt = 0; cnt < conflictsno; ++cnt)
|
||||
iconf[cnt] = BYTE_GET (econf32[cnt]);
|
||||
@ -17089,7 +17092,10 @@ process_mips_specific (Filedata * filedata)
|
||||
get_data (NULL, filedata, conflicts_offset,
|
||||
sizeof (*econf64), conflictsno, _("conflict"));
|
||||
if (!econf64)
|
||||
return FALSE;
|
||||
{
|
||||
free (iconf);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
for (cnt = 0; cnt < conflictsno; ++cnt)
|
||||
iconf[cnt] = BYTE_GET (econf64[cnt]);
|
||||
|
Loading…
Reference in New Issue
Block a user