Commit 30b639a8 by Matthew Gingell Committed by Tristan Gingold

cplus-dem.c (ada_demangle): Ensure demangled is freed.

2009-09-23  Matthew Gingell <gingell@adacore.com>

	* cplus-dem.c (ada_demangle): Ensure demangled is freed.

From-SVN: r152060
parent 457ff6a1
2009-09-23 Matthew Gingell <gingell@adacore.com>
* cplus-dem.c (ada_demangle): Ensure demangled is freed.
2009-09-22 Ozkan Sezer <sezeroz@gmail.com> 2009-09-22 Ozkan Sezer <sezeroz@gmail.com>
* choose-temp.c: Include unistd.h for mingw targets. * choose-temp.c: Include unistd.h for mingw targets.
......
...@@ -984,7 +984,10 @@ ada_demangle (const char *mangled, int option ATTRIBUTE_UNUSED) ...@@ -984,7 +984,10 @@ ada_demangle (const char *mangled, int option ATTRIBUTE_UNUSED)
goto Suppress; goto Suppress;
if (! changed) if (! changed)
return NULL; {
free (demangled);
return NULL;
}
else else
return demangled; return demangled;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment