[Lldb-commits] [lldb] r124155 - /lldb/trunk/source/Target/Target.cpp

Greg Clayton gclayton at apple.com
Mon Jan 24 15:35:47 PST 2011


Author: gclayton
Date: Mon Jan 24 17:35:47 2011
New Revision: 124155

URL: http://llvm.org/viewvc/llvm-project?rev=124155&view=rev
Log:
Fixed a crasher due to not checking if a shared pointer (m_last_created_breakpoint)
contained a valid object pointer.


Modified:
    lldb/trunk/source/Target/Target.cpp

Modified: lldb/trunk/source/Target/Target.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/Target.cpp?rev=124155&r1=124154&r2=124155&view=diff
==============================================================================
--- lldb/trunk/source/Target/Target.cpp (original)
+++ lldb/trunk/source/Target/Target.cpp Mon Jan 24 17:35:47 2011
@@ -326,8 +326,11 @@
             m_internal_breakpoint_list.Remove(break_id, false);
         else
         {
-            if (m_last_created_breakpoint->GetID() == break_id)
-                m_last_created_breakpoint.reset();
+            if (m_last_created_breakpoint)
+            {
+                if (m_last_created_breakpoint->GetID() == break_id)
+                    m_last_created_breakpoint.reset();
+            }
             m_breakpoint_list.Remove(break_id, true);
         }
         return true;





More information about the lldb-commits mailing list