forked from qt-creator/qt-creator
Editor: delete processor after canceling
Set a null proposal has the potential to restart the processor in combination with the invalidateCurrentRequestData from this cancelCurrentRequest will result in a restarted processor that is not tracked via m_asyncProcessor. Change-Id: Ia0e0d49564170a1e705994933d07e00c23f24f5d Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -292,7 +292,7 @@ void CodeAssistantPrivate::cancelCurrentRequest()
|
|||||||
}
|
}
|
||||||
if (m_asyncProcessor) {
|
if (m_asyncProcessor) {
|
||||||
m_asyncProcessor->cancel();
|
m_asyncProcessor->cancel();
|
||||||
m_asyncProcessor->setAsyncProposalAvailable(nullptr);
|
delete m_asyncProcessor;
|
||||||
}
|
}
|
||||||
invalidateCurrentRequestData();
|
invalidateCurrentRequestData();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user