QmlProfiler: avoid idle engine cancelling other engine's process

Task-number: QTCREATORBUG-9643

Change-Id: Idd78aeb94af939d0641ad8e18c2e4f1a9bca4ba5
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
This commit is contained in:
Christiaan Janssen
2013-06-25 16:54:21 +02:00
committed by Kai Koehne
parent 67d66abf8f
commit bf467e258b

View File

@@ -259,6 +259,10 @@ void QmlProfilerEngine::cancelProcess()
{ {
QTC_ASSERT(d->m_profilerState, return); QTC_ASSERT(d->m_profilerState, return);
// no process to be canceled? (there might be multiple engines, but only one runs a process)
if (!d->m_runner)
return;
switch (d->m_profilerState->currentState()) { switch (d->m_profilerState->currentState()) {
case QmlProfilerStateManager::AppReadyToStop : { case QmlProfilerStateManager::AppReadyToStop : {
d->m_profilerState->setCurrentState(QmlProfilerStateManager::AppStopped); d->m_profilerState->setCurrentState(QmlProfilerStateManager::AppStopped);