diff --git a/cli/cmdlineparser.cpp b/cli/cmdlineparser.cpp index e27c5d38f..96a5dc736 100644 --- a/cli/cmdlineparser.cpp +++ b/cli/cmdlineparser.cpp @@ -714,7 +714,7 @@ bool CmdLineParser::ParseFromArgs(int argc, const char* const argv[]) _settings->platform(Settings::Native); else if (platform == "unspecified") _settings->platform(Settings::Unspecified); - else if (!_settings->platformFile(argv[0], platform)) { + else if (!_settings->loadPlatformFile(argv[0], platform)) { std::string message("cppcheck: error: unrecognized platform: \""); message += platform; message += "\"."; diff --git a/lib/platform.cpp b/lib/platform.cpp index 3722142e9..42d294fc2 100644 --- a/lib/platform.cpp +++ b/lib/platform.cpp @@ -154,7 +154,7 @@ bool cppcheck::Platform::platform(cppcheck::Platform::PlatformType type) return false; } -bool cppcheck::Platform::platformFile(const char exename[], const std::string &filename) +bool cppcheck::Platform::loadPlatformFile(const char exename[], const std::string &filename) { // open file.. tinyxml2::XMLDocument doc; diff --git a/lib/platform.h b/lib/platform.h index b84422552..4970f5f58 100644 --- a/lib/platform.h +++ b/lib/platform.h @@ -100,8 +100,13 @@ namespace cppcheck { /** set the platform type for predefined platforms */ bool platform(PlatformType type); - /** set the platform type for user specified platforms */ - bool platformFile(const char exename[], const std::string &filename); + /** + * load platform file + * @param exename application path + * @param filename platform filename + * @return returns true if file was loaded successfully + */ + bool loadPlatformFile(const char exename[], const std::string &filename); /** load platform from xml document, primarily for testing */ bool loadFromXmlDocument(const tinyxml2::XMLDocument *doc);