aboutsummaryrefslogtreecommitdiff
path: root/binutils/objdump.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2019-01-04 12:11:51 +0000
committerNick Clifton <nickc@redhat.com>2019-01-04 12:11:51 +0000
commitcf0ad5bbf2d3fdb751b5f3f49e55d251d48c7416 (patch)
tree30a597593dc59479b52fcdfa707690be61236ffd /binutils/objdump.c
parent677bd4c69d0eda4f2ae635d793f23c0b1413a9e9 (diff)
downloadgdb-cf0ad5bbf2d3fdb751b5f3f49e55d251d48c7416.zip
gdb-cf0ad5bbf2d3fdb751b5f3f49e55d251d48c7416.tar.gz
gdb-cf0ad5bbf2d3fdb751b5f3f49e55d251d48c7416.tar.bz2
Fix ridiculously small memory leak.
PR 24001 * objcopy.c (copy_object): Free dhandle after writing out the debug information. * objdump.c (dump_bfd): Free dhandle after printing out the debug information.
Diffstat (limited to 'binutils/objdump.c')
-rw-r--r--binutils/objdump.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/binutils/objdump.c b/binutils/objdump.c
index 37a28d5..220d93a 100644
--- a/binutils/objdump.c
+++ b/binutils/objdump.c
@@ -3692,6 +3692,8 @@ dump_bfd (bfd *abfd)
bfd_get_filename (abfd));
exit_status = 1;
}
+
+ free (dhandle);
}
/* PR 6483: If there was no STABS debug info in the file, try
DWARF instead. */