aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/projectexplorer/runcontrol.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/projectexplorer/runcontrol.cpp')
-rw-r--r--src/plugins/projectexplorer/runcontrol.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/plugins/projectexplorer/runcontrol.cpp b/src/plugins/projectexplorer/runcontrol.cpp
index a5b45af2ef..7f0a0676ca 100644
--- a/src/plugins/projectexplorer/runcontrol.cpp
+++ b/src/plugins/projectexplorer/runcontrol.cpp
@@ -836,10 +836,12 @@ void RunControl::setupFormatter(OutputFormatter *formatter) const
}
}
formatter->setLineParsers(parsers);
- Utils::FileInProjectFinder fileFinder;
- fileFinder.setProjectDirectory(project()->projectDirectory());
- fileFinder.setProjectFiles(project()->files(Project::AllFiles));
- formatter->setFileFinder(fileFinder);
+ if (project()) {
+ Utils::FileInProjectFinder fileFinder;
+ fileFinder.setProjectDirectory(project()->projectDirectory());
+ fileFinder.setProjectFiles(project()->files(Project::AllFiles));
+ formatter->setFileFinder(fileFinder);
+ }
}
Utils::Id RunControl::runMode() const