diff options
author | emaste <emaste@FreeBSD.org> | 2013-12-03 19:23:54 +0000 |
---|---|---|
committer | emaste <emaste@FreeBSD.org> | 2013-12-03 19:23:54 +0000 |
commit | e75cbd9d8d61004a7f53a7bc08490fa932daa589 (patch) | |
tree | ba627d06612b80ba6e3256d311edf689335b6603 /contrib/llvm/tools/lldb/source/Target/StackFrameList.cpp | |
parent | 6221ad905044551fac57fb9353660c4e20e86c1d (diff) | |
parent | 0f31a1ef7ecf609d469ee5b34b3f0cb24ae3492d (diff) | |
download | FreeBSD-src-e75cbd9d8d61004a7f53a7bc08490fa932daa589.zip FreeBSD-src-e75cbd9d8d61004a7f53a7bc08490fa932daa589.tar.gz |
Update LLDB to upstream r196259 snapshot
Sponsored by: DARPA, AFRL
Diffstat (limited to 'contrib/llvm/tools/lldb/source/Target/StackFrameList.cpp')
-rw-r--r-- | contrib/llvm/tools/lldb/source/Target/StackFrameList.cpp | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/contrib/llvm/tools/lldb/source/Target/StackFrameList.cpp b/contrib/llvm/tools/lldb/source/Target/StackFrameList.cpp index eaac361..631a77b 100644 --- a/contrib/llvm/tools/lldb/source/Target/StackFrameList.cpp +++ b/contrib/llvm/tools/lldb/source/Target/StackFrameList.cpp @@ -301,7 +301,7 @@ StackFrameList::GetFramesUpTo(uint32_t end_idx) if (reg_ctx_sp) { - const bool success = unwinder->GetFrameInfoAtIndex(idx, cfa, pc); + const bool success = unwinder && unwinder->GetFrameInfoAtIndex(idx, cfa, pc); // There shouldn't be any way not to get the frame info for frame 0. // But if the unwinder can't make one, lets make one by hand with the // SP as the CFA and see if that gets any further. @@ -329,7 +329,7 @@ StackFrameList::GetFramesUpTo(uint32_t end_idx) } else { - const bool success = unwinder->GetFrameInfoAtIndex(idx, cfa, pc); + const bool success = unwinder && unwinder->GetFrameInfoAtIndex(idx, cfa, pc); if (!success) { // We've gotten to the end of the stack. @@ -451,14 +451,17 @@ StackFrameList::GetFramesUpTo(uint32_t end_idx) { if (end_idx < m_concrete_frames_fetched) return; - - uint32_t num_frames = unwinder->GetFramesUpTo(end_idx); - if (num_frames <= end_idx + 1) + + if (unwinder) { - //Done unwinding. - m_concrete_frames_fetched = UINT32_MAX; + uint32_t num_frames = unwinder->GetFramesUpTo(end_idx); + if (num_frames <= end_idx + 1) + { + //Done unwinding. + m_concrete_frames_fetched = UINT32_MAX; + } + m_frames.resize(num_frames); } - m_frames.resize(num_frames); } } |