ModelEditor: Fix crash for projects without rootProjectNode

Those projects will be scanned when the file list changes after
the parser is done.

Change-Id: I15d6a19196d373d8dddaaa4f9d7f34df8740f10f
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Tobias Hunger
2017-03-16 16:19:41 +01:00
committed by hjk
parent b4049ada7f
commit 323117a493

View File

@@ -382,6 +382,9 @@ void ModelIndexer::onProjectFileListChanged(ProjectExplorer::Project *project)
void ModelIndexer::scanProject(ProjectExplorer::Project *project)
{
if (!project->rootProjectNode())
return;
// TODO harmonize following code with findFirstModel()?
QStringList files = project->files(ProjectExplorer::Project::SourceFiles);
QQueue<QueuedFile> filesQueue;