fix compiler warning

This commit is contained in:
vaxerski 2022-11-06 14:28:15 +00:00
parent 5295244026
commit b4c45aa2e3

View file

@ -1071,7 +1071,7 @@ void CConfigManager::parseLine(std::string& line) {
} }
size_t startPos = 0; size_t startPos = 0;
while (startPos < line.length() - 1 && (startPos = line.find("##", startPos)) != std::string::npos) { while ((startPos = line.find("##", startPos)) != std::string::npos && startPos < line.length() - 1 && startPos > 0) {
line.replace(startPos, 2, "#"); line.replace(startPos, 2, "#");
startPos++; startPos++;
} }