From 6b662c73539b12b870f77f01fea2a649b9546137 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Mon, 29 Jul 2019 11:22:57 +0200 Subject: [PATCH] Fixed #8777 (GUI: Wrong platform used and shown in "Analysis Log") --- gui/mainwindow.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp index 2ac00c57e..d7a05ebe2 100644 --- a/gui/mainwindow.cpp +++ b/gui/mainwindow.cpp @@ -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());