Commit 99e92dce authored by Daniel Teske's avatar Daniel Teske
Browse files

QmakeProject: Fix crash on unloading projects



The QmakeVfs needs to be deleted after all evaluations have been
canceled. Those are canceled in the destructors of the nodes, so
delete the nodes before deleting m_qmakeVfs

Task-number: QTCREATORBUG-13421
Change-Id: I5883f5b2daa6a13ef4facf9b9dccc125a069df94
Reviewed-by: Orgad Shaneh's avatarOrgad Shaneh <orgads@gmail.com>
parent f6a9d01d
......@@ -376,7 +376,6 @@ QmakeProject::~QmakeProject()
m_codeModelFuture.cancel();
m_asyncUpdateState = ShuttingDown;
m_manager->unregisterProject(this);
delete m_qmakeVfs;
delete m_projectFiles;
m_cancelEvaluate = true;
// Deleting the root node triggers a few things, make sure rootProjectNode
......@@ -385,6 +384,7 @@ QmakeProject::~QmakeProject()
m_rootProjectNode = 0;
delete root;
Q_ASSERT(m_qmakeGlobalsRefCnt == 0);
delete m_qmakeVfs;
}
void QmakeProject::updateFileList()
......
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