Avoid this unnecessary copy by using a "const" reference.

- Reported by Sonarcloud
This commit is contained in:
Eduardo Arias 2024-10-19 13:13:38 -03:00
parent d1e7e7b4f2
commit b0497d9cb9

View File

@ -97,7 +97,7 @@ int main(int argc, char **argv) {
}
if (const auto *rwo = dynamic_cast<modsecurity::RuleWithOperator *>(z.get())) {
const auto op = rwo->getOperatorName();
const auto &op = rwo->getOperatorName();
if (operators.count(op) > 0) {
operators[op] = 1 + operators[op];
} else {