aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite/ld-arm
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2025-01-23 10:24:46 +1030
committerAlan Modra <amodra@gmail.com>2025-01-23 15:40:09 +1030
commit3097045a18a8878bc40548bd0995f9bad5609c43 (patch)
tree51bf4955c5eed8bc04338b29201aa7117acd460c /ld/testsuite/ld-arm
parentee8f3b6c78e1df055184635aedfe0ac1333a6706 (diff)
downloadgdb-3097045a18a8878bc40548bd0995f9bad5609c43.zip
gdb-3097045a18a8878bc40548bd0995f9bad5609c43.tar.gz
gdb-3097045a18a8878bc40548bd0995f9bad5609c43.tar.bz2
ld plugin bfd_make_readable leak
bfd_make_readable leaks memory that could be freed by _free_cached_info except that does too much in releasing all bfd memory. (The fact that we had to hack around keeping the bfd filename also indicates that releasing all bfd memory was too much.) So this patch moves code releasing bfd_alloc'd memory to the COFF _free_cached_info, where the syms and suchlike are released. This is the memory that archive handling wants to release in the call there to bfd_free_cached_info. * coffgen.c (_bfd_coff_free_cached_info): Release syms. * opncls.c (_bfd_new_bfd): Correct error return path. (_bfd_free_cached_info): Don't kill all abfd->memory. (_bfd_delete_bfd): Adjust fallback for bfd_free_cached_info. (bfd_make_readable): Call target bfd_free_cached_info and _bfd_free_cached_info plus reinstate section_htab.
Diffstat (limited to 'ld/testsuite/ld-arm')
0 files changed, 0 insertions, 0 deletions