From: Michael Snyder Date: Mon, 7 Mar 2011 18:34:31 +0000 (+0000) Subject: 2011-03-06 Michael Snyder X-Git-Tag: cgen-snapshot-20110401~366 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e6040cbdcd2feb312855101655e6c314f8fc3d25;p=platform%2Fupstream%2Fbinutils.git 2011-03-06 Michael Snyder * main.c (captured_main): Fix memory leak. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index cf0b129..85abd06 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,7 @@ +2011-03-06 Michael Snyder + + * main.c (captured_main): Fix memory leak. + 2011-03-07 Andreas Schwab * ada-lang.c (compare_names): Call is_name_suffix with string1 diff --git a/gdb/main.c b/gdb/main.c index 6be4805..ff305a1 100644 --- a/gdb/main.c +++ b/gdb/main.c @@ -352,11 +352,14 @@ captured_main (void *data) GDB_DATADIR_RELOCATABLE); #ifdef WITH_PYTHON_PATH - /* For later use in helping Python find itself. */ - python_libdir = relocate_directory (argv[0], - concat (WITH_PYTHON_PATH, - SLASH_STRING, "lib", NULL), - PYTHON_PATH_RELOCATABLE); + { + /* For later use in helping Python find itself. */ + char *tmp = concat (WITH_PYTHON_PATH, SLASH_STRING, "lib", NULL); + + python_libdir = relocate_directory (argv[0], tmp, + PYTHON_PATH_RELOCATABLE); + xfree (tmp); + } #endif #ifdef RELOC_SRCDIR