diff options
author | Jim Ingham <jingham@apple.com> | 2011-05-17 01:10:11 +0000 |
---|---|---|
committer | Jim Ingham <jingham@apple.com> | 2011-05-17 01:10:11 +0000 |
commit | 160f78c5846c8fe774a1ccfc044d263b7b30ad9c (patch) | |
tree | 332b9c5e803a03b373d8609960a5f32b35f48671 /lldb/source/Target/ThreadPlanCallFunction.cpp | |
parent | ceee5e813364a34db3ad99926fd05dce69e4bb44 (diff) | |
download | llvm-160f78c5846c8fe774a1ccfc044d263b7b30ad9c.zip llvm-160f78c5846c8fe774a1ccfc044d263b7b30ad9c.tar.gz llvm-160f78c5846c8fe774a1ccfc044d263b7b30ad9c.tar.bz2 |
Fix the error message when an expression evaluation is interrupted by a crash/breakpoint hit to
give the reason for the interrupt. Also make sure it we don't want to unwind from the evaluation
we print something if it is interrupted.
llvm-svn: 131448
Diffstat (limited to 'lldb/source/Target/ThreadPlanCallFunction.cpp')
-rw-r--r-- | lldb/source/Target/ThreadPlanCallFunction.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/lldb/source/Target/ThreadPlanCallFunction.cpp b/lldb/source/Target/ThreadPlanCallFunction.cpp index 371f3a4..7d798fc 100644 --- a/lldb/source/Target/ThreadPlanCallFunction.cpp +++ b/lldb/source/Target/ThreadPlanCallFunction.cpp @@ -282,6 +282,7 @@ ThreadPlanCallFunction::DoTakedown () if (log) log->Printf ("DoTakedown called for thread 0x%4.4x, m_valid: %d complete: %d.\n", m_thread.GetID(), m_valid, IsPlanComplete()); m_takedown_done = true; + m_real_stop_info_sp = GetPrivateStopReason(); m_thread.RestoreThreadStateFromCheckpoint(m_stored_thread_state); SetPlanComplete(); ClearBreakpoints(); @@ -327,6 +328,8 @@ ThreadPlanCallFunction::ValidatePlan (Stream *error) bool ThreadPlanCallFunction::PlanExplainsStop () { + m_real_stop_info_sp = GetPrivateStopReason(); + // If our subplan knows why we stopped, even if it's done (which would forward the question to us) // we answer yes. if(m_subplan_sp.get() != NULL && m_subplan_sp->PlanExplainsStop()) @@ -343,11 +346,10 @@ ThreadPlanCallFunction::PlanExplainsStop () // Otherwise, check the case where we stopped for an internal breakpoint, in that case, continue on. // If it is not an internal breakpoint, consult OkayToDiscard. - StopInfoSP stop_info_sp = GetPrivateStopReason(); - if (stop_info_sp && stop_info_sp->GetStopReason() == eStopReasonBreakpoint) + if (m_real_stop_info_sp && m_real_stop_info_sp->GetStopReason() == eStopReasonBreakpoint) { - uint64_t break_site_id = stop_info_sp->GetValue(); + uint64_t break_site_id = m_real_stop_info_sp->GetValue(); BreakpointSiteSP bp_site_sp = m_thread.GetProcess().GetBreakpointSiteList().FindByID(break_site_id); if (bp_site_sp) { |