Codechange: use const auto & instead of making a copy

This commit is contained in:
Rubidium
2025-03-08 20:42:02 +01:00
committed by rubidium42
parent 91d22f7617
commit a23dda7ffe
5 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -189,7 +189,7 @@ size_t OneOfManySettingDesc::ParseSingleValue(const char *str, size_t len, const
if (isdigit(*str)) return std::strtoul(str, nullptr, 0);
size_t idx = 0;
for (auto one : many) {
for (const auto &one : many) {
if (one.size() == len && strncmp(one.c_str(), str, len) == 0) return idx;
idx++;
}