summaryrefslogtreecommitdiff
path: root/binutils/ar.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2011-03-25 17:18:54 +0000
committerNick Clifton <nickc@redhat.com>2011-03-25 17:18:54 +0000
commit8e4850a9e39ff6541d7e705710540191f7e23dc8 (patch)
tree7cd5121f21a74e2796bde340b7bfd0b9a008ef3f /binutils/ar.c
parenta1bc0327a3df4e35e5b923913536c31ca85f16dc (diff)
downloadbinutils-gdb-8e4850a9e39ff6541d7e705710540191f7e23dc8.tar.gz
* ar.c (write_archive): Plug memory leak.
Diffstat (limited to 'binutils/ar.c')
-rw-r--r--binutils/ar.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/binutils/ar.c b/binutils/ar.c
index 263795fb7ee..206c7a9781d 100644
--- a/binutils/ar.c
+++ b/binutils/ar.c
@@ -1069,6 +1069,7 @@ write_archive (bfd *iarch)
if (smart_rename (new_name, old_name, 0) != 0)
xexit (1);
+ free (old_name);
}
/* Return a pointer to the pointer to the entry which should be rplacd'd