Commit 175afabb authored by Orgad Shaneh's avatar Orgad Shaneh Committed by Orgad Shaneh

Cdb: Do not crash if no device is set

It still fails with a soft assertion, but at least doesn't crash.

Task-number: QTCREATORBUG-19160
Change-Id: I3779f64e752abf9d3779219552a4a1be648f1dea
Reviewed-by: David Schulz's avatarDavid Schulz <david.schulz@qt.io>
parent c0bffe1d
......@@ -880,7 +880,10 @@ void CdbEngine::doInterruptInferior(SpecialStopMode sm)
showMessage(QString("Interrupting process %1...").arg(inferiorPid()), LogMisc);
QTC_ASSERT(!m_signalOperation, notifyInferiorStopFailed(); return;);
m_signalOperation = runTool()->device()->signalOperation();
if (DebuggerRunTool *rt = runTool()) {
if (IDevice::ConstPtr device = rt->device())
m_signalOperation = device->signalOperation();
}
m_specialStopMode = sm;
QTC_ASSERT(m_signalOperation, notifyInferiorStopFailed(); return;);
connect(m_signalOperation.data(), &DeviceProcessSignalOperation::finished,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment