From: Michael Snyder Date: Mon, 14 Mar 2011 19:05:39 +0000 (+0000) Subject: 2011-03-08 Michael Snyder X-Git-Tag: cgen-snapshot-20110401~266 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c30fe01daf7e4b8d1a82b9ea2137f30e20980c70;p=external%2Fbinutils.git 2011-03-08 Michael Snyder * wrstabs.c (stab_start_struct_type): Close memory leak. --- diff --git a/binutils/ChangeLog b/binutils/ChangeLog index 2ec667f..5172026 100644 --- a/binutils/ChangeLog +++ b/binutils/ChangeLog @@ -1,5 +1,7 @@ 2011-03-14 Michael Snyder + * wrstabs.c (stab_start_struct_type): Close memory leak. + * readelf.c (process_version_sections): Free symbols. * nm.c (display_rel_file): Free symsizes. diff --git a/binutils/wrstabs.c b/binutils/wrstabs.c index 0ca861c..bbf257e 100644 --- a/binutils/wrstabs.c +++ b/binutils/wrstabs.c @@ -1312,9 +1312,7 @@ stab_start_struct_type (void *p, const char *tag, unsigned int id, struct stab_write_handle *info = (struct stab_write_handle *) p; long tindex; bfd_boolean definition; - char *buf; - - buf = (char *) xmalloc (40); + char buf[40]; if (id == 0) {