diff --git a/src/plugins/debugger/debuggerengine.cpp b/src/plugins/debugger/debuggerengine.cpp index 543ad8f8190..93a2d69aada 100644 --- a/src/plugins/debugger/debuggerengine.cpp +++ b/src/plugins/debugger/debuggerengine.cpp @@ -1030,39 +1030,37 @@ RunControl *DebuggerEnginePrivate::runControl() const void DebuggerEngine::notifyEngineIll() { - runControl()->initiateStop(); - return; //#ifdef WITH_BENCHMARK // CALLGRIND_STOP_INSTRUMENTATION; // CALLGRIND_DUMP_STATS; //#endif -// showMessage("NOTE: ENGINE ILL ******"); -// runTool()->startDying(); -// d->m_lastGoodState = d->m_state; -// switch (state()) { -// case InferiorRunRequested: -// case InferiorRunOk: -// // The engine does not look overly ill right now, so attempt to -// // properly interrupt at least once. If that fails, we are on the -// // shutdown path due to d->m_targetState anyways. -// setState(InferiorStopRequested, true); -// showMessage("ATTEMPT TO INTERRUPT INFERIOR"); -// interruptInferior(); -// break; -// case InferiorStopRequested: -// notifyInferiorStopFailed(); -// break; -// case InferiorStopOk: -// showMessage("FORWARDING STATE TO InferiorShutdownFailed"); -// setState(InferiorShutdownFailed, true); -// if (isMasterEngine()) -// d->queueShutdownEngine(); -// break; -// default: -// if (isMasterEngine()) -// d->queueShutdownEngine(); -// break; -// } + showMessage("NOTE: ENGINE ILL ******"); + runTool()->startDying(); + d->m_lastGoodState = d->m_state; + switch (state()) { + case InferiorRunRequested: + case InferiorRunOk: + // The engine does not look overly ill right now, so attempt to + // properly interrupt at least once. If that fails, we are on the + // shutdown path due to d->m_targetState anyways. + setState(InferiorStopRequested, true); + showMessage("ATTEMPT TO INTERRUPT INFERIOR"); + interruptInferior(); + break; + case InferiorStopRequested: + notifyInferiorStopFailed(); + break; + case InferiorStopOk: + showMessage("FORWARDING STATE TO InferiorShutdownFailed"); + setState(InferiorShutdownFailed, true); + if (isMasterEngine()) + d->queueShutdownEngine(); + break; + default: + if (isMasterEngine()) + d->queueShutdownEngine(); + break; + } } void DebuggerEngine::notifyEngineSpontaneousShutdown()