1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Address some clang-tidy warnings

This commit is contained in:
sfan5 2023-12-23 13:02:17 +01:00
parent 322c4a5b2b
commit 961652c2e9
17 changed files with 35 additions and 36 deletions

View file

@ -403,7 +403,7 @@ bool Settings::updateConfigFile(const char *filename)
bool Settings::parseCommandLine(int argc, char *argv[],
std::map<std::string, ValueSpec> &allowed_options)
const std::map<std::string, ValueSpec> &allowed_options)
{
int nonopt_index = 0;
for (int i = 1; i < argc; i++) {
@ -424,8 +424,7 @@ bool Settings::parseCommandLine(int argc, char *argv[],
std::string name = arg_name.substr(2);
std::map<std::string, ValueSpec>::iterator n;
n = allowed_options.find(name);
auto n = allowed_options.find(name);
if (n == allowed_options.end()) {
errorstream << "Unknown command-line parameter \""
<< arg_name << "\"" << std::endl;