Author: spyffe
Date: Wed Sep 28 19:16:37 2016
New Revision: 282653

URL: http://llvm.org/viewvc/llvm-project?rev=282653&view=rev
Log:
Introduced a null check to avoid a crash in a test on i386.

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

Modified: lldb/trunk/source/Target/StackFrame.cpp
URL: 
http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/StackFrame.cpp?rev=282653&r1=282652&r2=282653&view=diff
==============================================================================
--- lldb/trunk/source/Target/StackFrame.cpp (original)
+++ lldb/trunk/source/Target/StackFrame.cpp Wed Sep 28 19:16:37 2016
@@ -1419,6 +1419,10 @@ ValueObjectSP GetValueForDereferincingOf
 
   Error error;
   ValueObjectSP pointee = base->Dereference(error);
+    
+  if (!pointee) {
+    return ValueObjectSP();
+  }
 
   if (offset >= 0 && uint64_t(offset) >= pointee->GetByteSize()) {
     int64_t index = offset / pointee->GetByteSize();


_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to