Fixed #8777 (GUI: Wrong platform used and shown in "Analysis Log")

This commit is contained in:
Daniel Marjamäki 2019-07-29 11:22:57 +02:00
parent a1214348c0
commit 6b662c7353
1 changed files with 1 additions and 1 deletions

View File

@ -928,7 +928,7 @@ Settings MainWindow::getCppcheckSettings()
result.jobs = mSettings->value(SETTINGS_CHECK_THREADS, 1).toInt();
result.inlineSuppressions = mSettings->value(SETTINGS_INLINE_SUPPRESSIONS, false).toBool();
result.inconclusive = mSettings->value(SETTINGS_INCONCLUSIVE_ERRORS, false).toBool();
if (result.platformType == cppcheck::Platform::Unspecified)
if (!mProjectFile || result.platformType == cppcheck::Platform::Unspecified)
result.platform((cppcheck::Platform::PlatformType) mSettings->value(SETTINGS_CHECKED_PLATFORM, 0).toInt());
result.standards.setCPP(mSettings->value(SETTINGS_STD_CPP, QString()).toString().toStdString());
result.standards.setC(mSettings->value(SETTINGS_STD_C, QString()).toString().toStdString());