summaryrefslogtreecommitdiffstats
path: root/lldb/source/Core/State.cpp
diff options
context:
space:
mode:
authorGreg Clayton <gclayton@apple.com>2011-11-17 01:23:07 +0000
committerGreg Clayton <gclayton@apple.com>2011-11-17 01:23:07 +0000
commit2637f82542071c5ce21aa79ae897c01d29c8f560 (patch)
tree12108f1cf911d90e23df87a73b612e2482a7b8b0 /lldb/source/Core/State.cpp
parent78d614883f2f751ea9334f2a16b3bdedcf15be5a (diff)
downloadbcm5719-llvm-2637f82542071c5ce21aa79ae897c01d29c8f560.tar.gz
bcm5719-llvm-2637f82542071c5ce21aa79ae897c01d29c8f560.zip
Fixed an issue with the pthread_setspecific() where we weren't NULL-ing out
the thread specific data and were destroying the thread specfic data more than once. Also added the ability to ask a lldb::StateType if it is stopped with an additional paramter of "must_exist" which means that the state must be a stopped state for a process that still exists. This means that eStateExited and eStateUnloaded will no longer return true if "must_exist" is set to true. llvm-svn: 144875
Diffstat (limited to 'lldb/source/Core/State.cpp')
-rw-r--r--lldb/source/Core/State.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/lldb/source/Core/State.cpp b/lldb/source/Core/State.cpp
index 8cb748ff67f..c660477f1c4 100644
--- a/lldb/source/Core/State.cpp
+++ b/lldb/source/Core/State.cpp
@@ -90,7 +90,7 @@ lldb_private::StateIsRunningState (StateType state)
}
bool
-lldb_private::StateIsStoppedState (StateType state)
+lldb_private::StateIsStoppedState (StateType state, bool must_exist)
{
switch (state)
{
@@ -105,9 +105,11 @@ lldb_private::StateIsStoppedState (StateType state)
break;
case eStateUnloaded:
+ case eStateExited:
+ return !must_exist;
+
case eStateStopped:
case eStateCrashed:
- case eStateExited:
case eStateSuspended:
return true;
}
OpenPOWER on IntegriCloud