fixed device configs

This commit is contained in:
vaxerski
2022-07-28 21:38:30 +02:00
parent 13d9c85e4e
commit 4076a3b6d7
2 changed files with 31 additions and 19 deletions

View File

@@ -1105,7 +1105,11 @@ SConfigValue CConfigManager::getConfigValueSafeDevice(const std::string& dev, co
// fallback if not set explicitly
if (!copy.set) {
for (auto& cv : configValues) {
if (cv.first.find(val) == cv.first.length() - val.length()) {
auto foundIt = cv.first.find(val);
if (foundIt == std::string::npos)
continue;
if (foundIt == cv.first.length() - val.length()) {
copy = cv.second;
}
}