Fixed an issue with the UnwindLLDB code where if there were inlined stack
frames, UnwindLLDB could create the incorrect RegisterContext for a given
stack frame because it was using the frame index (not the concrete frame
index). This was causing crashes when doing backtraces through the
SBFrame::GetFP() because a NULL register context was being returned for the
deepest stack frame.
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@123052 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Plugins/Process/Utility/UnwindLLDB.cpp b/source/Plugins/Process/Utility/UnwindLLDB.cpp
index a1b030b..75f92bb 100644
--- a/source/Plugins/Process/Utility/UnwindLLDB.cpp
+++ b/source/Plugins/Process/Utility/UnwindLLDB.cpp
@@ -167,7 +167,7 @@
UnwindLLDB::CreateRegisterContextForFrame (StackFrame *frame)
{
lldb::RegisterContextSP reg_ctx_sp;
- uint32_t idx = frame->GetFrameIndex ();
+ uint32_t idx = frame->GetConcreteFrameIndex ();
if (idx == 0)
{