forked from qt-creator/qt-creator
QbsProjectManager: Fix potential null pointer access
We retrieved the watcher result from the wrong pointer. Fixes: QTCREATORBUG-23924 Change-Id: I876d8adc0aef011deb3f5827f3e50c43a8d92dfc Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -480,7 +480,7 @@ void QbsBuildSystem::updateProjectNodes(const std::function<void ()> &continuati
|
||||
m_treeCreationWatcher = new TreeCreationWatcher(this);
|
||||
connect(m_treeCreationWatcher, &TreeCreationWatcher::finished, this,
|
||||
[this, watcher = m_treeCreationWatcher, continuation] {
|
||||
std::unique_ptr<QbsProjectNode> rootNode(m_treeCreationWatcher->result());
|
||||
std::unique_ptr<QbsProjectNode> rootNode(watcher->result());
|
||||
if (watcher != m_treeCreationWatcher) {
|
||||
watcher->deleteLater();
|
||||
return;
|
||||
|
Reference in New Issue
Block a user