[Lldb-commits] [lldb] r191619 - Fix a memory leak. Found by both scan-build and coverity. Close CID 1096442

Sylvestre Ledru sylvestre at debian.org
Sat Sep 28 08:50:23 PDT 2013


Author: sylvestre
Date: Sat Sep 28 10:50:23 2013
New Revision: 191619

URL: http://llvm.org/viewvc/llvm-project?rev=191619&view=rev
Log:
Fix a memory leak. Found by both scan-build and coverity. Close CID 1096442


Modified:
    lldb/trunk/source/Host/common/Host.cpp

Modified: lldb/trunk/source/Host/common/Host.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Host/common/Host.cpp?rev=191619&r1=191618&r2=191619&view=diff
==============================================================================
--- lldb/trunk/source/Host/common/Host.cpp (original)
+++ lldb/trunk/source/Host/common/Host.cpp Sat Sep 28 10:50:23 2013
@@ -761,6 +761,8 @@ Host::SetShortThreadName (lldb::pid_t pi
         }
         return Host::SetThreadName (pid, tid, namebuf);
     }
+
+    ::free(namebuf);
     return false;
 }
 





More information about the lldb-commits mailing list