aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp')
-rw-r--r--lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp b/lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp
index 8e010a5..4158e3d 100644
--- a/lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp
+++ b/lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp
@@ -259,6 +259,25 @@ NativeThreadLinux::SetStoppedBySignal (uint32_t signo)
m_stop_info.details.signal.signo = signo;
}
+bool
+NativeThreadLinux::IsStopped (int *signo)
+{
+ if (!StateIsStoppedState (m_state, false))
+ return false;
+
+ // If we are stopped by a signal, return the signo.
+ if (signo &&
+ m_state == StateType::eStateStopped &&
+ m_stop_info.reason == StopReason::eStopReasonSignal)
+ {
+ *signo = m_stop_info.details.signal.signo;
+ }
+
+ // Regardless, we are stopped.
+ return true;
+}
+
+
void
NativeThreadLinux::SetStoppedByExec ()
{