Don't have ExecutionContextRef::SetTargetPtr fill in the frame
information if we're not stopped. This could try to read registers etc when the process is still running and debug builds of lldb would assert down in GDBRemoteRegisterContext.cpp ReadRegisterBytes because we couldn't get the sequence mutex for talking to the remote system. Non-debug builds would just silently fail when doing this. <rdar://problem/11941758> llvm-svn: 160829
This commit is contained in:
parent
e807e45bff
commit
8d3e8240d8
|
@ -643,7 +643,7 @@ ExecutionContextRef::SetTargetPtr (Target* target, bool adopt_selected)
|
|||
if (!thread_sp)
|
||||
thread_sp = process_sp->GetThreadList().GetThreadAtIndex(0);
|
||||
|
||||
if (thread_sp)
|
||||
if (thread_sp && process_sp->GetState() == lldb::eStateStopped)
|
||||
{
|
||||
SetThreadSP (thread_sp);
|
||||
lldb::StackFrameSP frame_sp (thread_sp->GetSelectedFrame());
|
||||
|
|
Loading…
Reference in New Issue