forked from OSchip/llvm-project
Clean up stop hook output in case a hook restarts.
I was warning about the fact that this will abort further stop hooks, but didn't check that there WAS a further stop hook. Also the warning was missing a newline. llvm-svn: 319730
This commit is contained in:
parent
80b55ee62d
commit
45816d6b91
|
@ -2679,6 +2679,10 @@ void Target::RunStopHooks() {
|
|||
|
||||
if (!m_process_sp)
|
||||
return;
|
||||
|
||||
// Somebody might have restarted the process:
|
||||
if (m_process_sp->GetState() != eStateStopped)
|
||||
return;
|
||||
|
||||
// <rdar://problem/12027563> make sure we check that we are not stopped
|
||||
// because of us running a user expression
|
||||
|
@ -2784,9 +2788,12 @@ void Target::RunStopHooks() {
|
|||
// running the stop hooks.
|
||||
if ((result.GetStatus() == eReturnStatusSuccessContinuingNoResult) ||
|
||||
(result.GetStatus() == eReturnStatusSuccessContinuingResult)) {
|
||||
result.AppendMessageWithFormat("Aborting stop hooks, hook %" PRIu64
|
||||
" set the program running.",
|
||||
cur_hook_sp->GetID());
|
||||
// But only complain if there were more stop hooks to do:
|
||||
StopHookCollection::iterator tmp = pos;
|
||||
if (++tmp != end)
|
||||
result.AppendMessageWithFormat("\nAborting stop hooks, hook %" PRIu64
|
||||
" set the program running.\n",
|
||||
cur_hook_sp->GetID());
|
||||
keep_going = false;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue