Cppcheck: Fix; Do not run clang twice

This commit is contained in:
Daniel Marjamäki 2020-12-29 12:43:21 +01:00
parent 7719b27e44
commit 1e9f67936e
1 changed files with 1 additions and 3 deletions

View File

@ -419,10 +419,8 @@ unsigned int CppCheck::check(const ImportProject::FileSettings &fs)
temp.mSettings.platform(fs.platformType);
if (mSettings.clang) {
temp.mSettings.includePaths.insert(temp.mSettings.includePaths.end(), fs.systemIncludePaths.cbegin(), fs.systemIncludePaths.cend());
temp.check(Path::simplifyPath(fs.filename));
return temp.check(Path::simplifyPath(fs.filename));
}
if (mSettings.clang)
return temp.check(fs.filename);
std::ifstream fin(fs.filename);
unsigned int returnValue = temp.checkFile(Path::simplifyPath(fs.filename), fs.cfg, fin);
mSettings.nomsg.addSuppressions(temp.mSettings.nomsg.getSuppressions());