diff options
Diffstat (limited to 'plugins/autotest/testtreemodel.cpp')
-rw-r--r-- | plugins/autotest/testtreemodel.cpp | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/plugins/autotest/testtreemodel.cpp b/plugins/autotest/testtreemodel.cpp index 7060203a41..e966446e9d 100644 --- a/plugins/autotest/testtreemodel.cpp +++ b/plugins/autotest/testtreemodel.cpp @@ -342,17 +342,16 @@ static void addProjectInformation(TestConfiguration *config, const QString &file QList<ProjectExplorer::RunConfiguration *> rcs = target->runConfigurations(); foreach (ProjectExplorer::RunConfiguration *rc, rcs) { - if (ProjectExplorer::LocalApplicationRunConfiguration *localRunConfiguration - = qobject_cast<ProjectExplorer::LocalApplicationRunConfiguration *>(rc)) { - if (localRunConfiguration->executable() == targetFile) { - hasDesktopTarget = true; - workDir = Utils::FileUtils::normalizePathName( - localRunConfiguration->workingDirectory()); - ProjectExplorer::EnvironmentAspect *envAsp - = localRunConfiguration->extraAspect<ProjectExplorer::EnvironmentAspect>(); - env = envAsp->environment(); - break; - } + ProjectExplorer::LocalApplicationRunConfiguration *localRunConfiguration + = qobject_cast<ProjectExplorer::LocalApplicationRunConfiguration *>(rc); + if (localRunConfiguration && localRunConfiguration->executable() == targetFile) { + hasDesktopTarget = true; + workDir = Utils::FileUtils::normalizePathName( + localRunConfiguration->workingDirectory()); + ProjectExplorer::EnvironmentAspect *envAsp + = localRunConfiguration->extraAspect<ProjectExplorer::EnvironmentAspect>(); + env = envAsp->environment(); + break; } } } |