diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2017-12-20 18:06:09 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2017-12-20 18:06:09 +0000 |
| commit | acac075be8bce18f411c310a849e242ec445dfc3 (patch) | |
| tree | 5f57769acef830514eb4eb67dfa628e32b17cbf5 /contrib/llvm/tools/lldb/source/Commands/CommandObjectThread.cpp | |
| parent | 10dc89a5a71075c0fecf74e6e43d206d7be795e9 (diff) | |
| parent | ef5d0b5e97ec8e6fa395d377b09aa7755e345b4f (diff) | |
Notes
Diffstat (limited to 'contrib/llvm/tools/lldb/source/Commands/CommandObjectThread.cpp')
| -rw-r--r-- | contrib/llvm/tools/lldb/source/Commands/CommandObjectThread.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/contrib/llvm/tools/lldb/source/Commands/CommandObjectThread.cpp b/contrib/llvm/tools/lldb/source/Commands/CommandObjectThread.cpp index 6a933df43e14..b68aa920b582 100644 --- a/contrib/llvm/tools/lldb/source/Commands/CommandObjectThread.cpp +++ b/contrib/llvm/tools/lldb/source/Commands/CommandObjectThread.cpp @@ -94,7 +94,7 @@ public: bool all_threads = false; if (command.GetArgumentCount() == 0) { Thread *thread = m_exe_ctx.GetThreadPtr(); - if (!HandleOneThread(thread->GetID(), result)) + if (!thread || !HandleOneThread(thread->GetID(), result)) return false; return result.Succeeded(); } else if (command.GetArgumentCount() == 1) { @@ -775,6 +775,12 @@ protected: else error = process->Resume(); + if (!error.Success()) { + result.AppendMessage(error.AsCString()); + result.SetStatus(eReturnStatusFailed); + return false; + } + // There is a race condition where this thread will return up the call // stack to the main command handler // and show an (lldb) prompt before HandlePrivateEvent (from |
