Commit c41e84fe authored by dt's avatar dt

Fix crash on removing a .pro file from the project with creator open

parent e6f36f0a
......@@ -178,7 +178,11 @@ void ProjectTreeWidget::foldersAboutToBeRemoved(FolderNode *, const QList<Folder
while(n) {
if (FolderNode *fn = qobject_cast<FolderNode *>(n)) {
if (list.contains(fn)) {
m_explorer->setCurrentNode(n->projectNode());
ProjectNode *pn = n->projectNode();
// Make sure the node we are switching too isn't going to be removed also
while (list.contains(pn))
pn = pn->parentFolderNode()->projectNode();
m_explorer->setCurrentNode(pn);
break;
}
}
......
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