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

Jim Ingham jingham at apple.com
Mon Aug 15 17:07:28 PDT 2011


Author: jingham
Date: Mon Aug 15 19:07:28 2011
New Revision: 137692

URL: http://llvm.org/viewvc/llvm-project?rev=137692&view=rev
Log:
Add missing check for non-NULL frame_sp.

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

Modified: lldb/trunk/source/Target/Thread.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/Thread.cpp?rev=137692&r1=137691&r2=137692&view=diff
==============================================================================
--- lldb/trunk/source/Target/Thread.cpp (original)
+++ lldb/trunk/source/Target/Thread.cpp Mon Aug 15 19:07:28 2011
@@ -1116,10 +1116,13 @@
     if (GetProcess().GetTarget().GetDebugger().GetUseExternalEditor())
     {
         StackFrameSP frame_sp = GetStackFrameAtIndex(start_frame);
-        SymbolContext frame_sc(frame_sp->GetSymbolContext (eSymbolContextLineEntry));
-        if (frame_sc.line_entry.line != 0 && frame_sc.line_entry.file)
+        if (frame_sp)
         {
-            Host::OpenFileInExternalEditor (frame_sc.line_entry.file, frame_sc.line_entry.line);
+            SymbolContext frame_sc(frame_sp->GetSymbolContext (eSymbolContextLineEntry));
+            if (frame_sc.line_entry.line != 0 && frame_sc.line_entry.file)
+            {
+                Host::OpenFileInExternalEditor (frame_sc.line_entry.file, frame_sc.line_entry.line);
+            }
         }
     }
     





More information about the lldb-commits mailing list