]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Avoid a double free when a binary has a build-id and no debuglink section.
authorTom Hughes <tom@compton.nu>
Tue, 19 Oct 2010 13:12:59 +0000 (13:12 +0000)
committerTom Hughes <tom@compton.nu>
Tue, 19 Oct 2010 13:12:59 +0000 (13:12 +0000)
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@11458

coregrind/m_debuginfo/readelf.c

index 503f2fedfade5c40d752cc455a31c9058f14d80c..7cf8ceb05de975a6cdcc250e087b9edd7ffc11df 100644 (file)
@@ -1063,6 +1063,7 @@ Addr find_debug_file( struct _DebugInfo* di,
 
       if ((addr = open_debug_file(debugpath, buildid, 0, size)) == 0) {
          ML_(dinfo_free)(debugpath);
+         debugpath = NULL;
       }
    }