summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--binutils/ChangeLog2
-rw-r--r--binutils/readelf.c6
2 files changed, 7 insertions, 1 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog
index 3f33f80bb6..2ec667f089 100644
--- a/binutils/ChangeLog
+++ b/binutils/ChangeLog
@@ -1,5 +1,7 @@
2011-03-14 Michael Snyder <msnyder@vmware.com>
+ * readelf.c (process_version_sections): Free symbols.
+
* nm.c (display_rel_file): Free symsizes.
2011-03-10 Nick Clifton <nickc@redhat.com>
diff --git a/binutils/readelf.c b/binutils/readelf.c
index 71f0501760..6a4a6e8d23 100644
--- a/binutils/readelf.c
+++ b/binutils/readelf.c
@@ -8053,7 +8053,10 @@ process_version_sections (FILE * file)
string_sec->sh_size,
_("version string table"));
if (!strtab)
- break;
+ {
+ free (symbols);
+ break;
+ }
printf (_("\nVersion symbols section '%s' contains %d entries:\n"),
SECTION_NAME (section), total);
@@ -8073,6 +8076,7 @@ process_version_sections (FILE * file)
if (!edata)
{
free (strtab);
+ free (symbols);
break;
}
OpenPOWER on IntegriCloud