forked from Imagelibrary/binutils-gdb
Fix memory leak in bfd_get_debug_link_info_1
* opncls.c (bfd_get_alt_debug_link_info): Don't bother freeing after bfd_malloc_and_get_section failure. (get_build_id): Likewise. (bfd_get_debug_link_info_1): Likewise. Free section contents when crc not present. * section.c (bfd_malloc_and_get_section): Document that the buffer is NULL on error return.
This commit is contained in:
@@ -1600,6 +1600,8 @@ SYNOPSIS
|
||||
DESCRIPTION
|
||||
Read all data from @var{section} in BFD @var{abfd}
|
||||
into a buffer, *@var{buf}, malloc'd by this function.
|
||||
Return @code{true} on success, @code{false} on failure in which
|
||||
case *@var{buf} will be NULL.
|
||||
*/
|
||||
|
||||
bool
|
||||
|
||||
Reference in New Issue
Block a user