diff --git a/src/lib/ebus/data.cpp b/src/lib/ebus/data.cpp index 7b8cf125..4500771c 100644 --- a/src/lib/ebus/data.cpp +++ b/src/lib/ebus/data.cpp @@ -793,9 +793,9 @@ result_t ValueListDataField::writeSymbols(size_t offset, istringstream* input, return numType->writeRawValue(numType->getReplacement(), offset, m_length, output, usedLength); } - for (map::const_iterator it = m_values.begin(); it != m_values.end(); ++it) { - if (it->second == inputStr) { - return numType->writeRawValue(it->first, offset, m_length, output, usedLength); + for (const auto& it : m_values) { + if (it.second == inputStr) { + return numType->writeRawValue(it.first, offset, m_length, output, usedLength); } } const char* str = inputStr.c_str();