Skip to content

Commit

Permalink
astyle formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
danmar committed Nov 13, 2020
1 parent 2e2d4a0 commit b7f8127
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
13 changes: 6 additions & 7 deletions cli/cmdlineparser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -578,13 +578,12 @@ bool CmdLineParser::parseFromArgs(int argc, const char* const argv[])
mSettings->plistOutput += '/';

const std::string plistOutput = Path::toNativeSeparators(mSettings->plistOutput);
if (!FileLister::isDirectory(plistOutput))
{
std::string message("cppcheck: error: plist folder does not exist: \"");
message += plistOutput;
message += "\".";
printMessage(message);
return false;
if (!FileLister::isDirectory(plistOutput)) {
std::string message("cppcheck: error: plist folder does not exist: \"");
message += plistOutput;
message += "\".";
printMessage(message);
return false;
}
}

Expand Down
2 changes: 1 addition & 1 deletion lib/cppcheck.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -516,7 +516,7 @@ unsigned int CppCheck::checkFile(const std::string& filename, const std::string
filename2 = filename.substr(filename.rfind('/') + 1);
else
filename2 = filename;
std::size_t fileNameHash = std::hash<std::string>{}(filename);
std::size_t fileNameHash = std::hash<std::string> {}(filename);
filename2 = mSettings.plistOutput + filename2.substr(0, filename2.find('.')) + "_" + std::to_string(fileNameHash) + ".plist";
plistFile.open(filename2);
plistFile << ErrorLogger::plistHeader(version(), files);
Expand Down

0 comments on commit b7f8127

Please sign in to comment.