mirror of
https://github.com/TES3MP/TES3MP.git
synced 2025-09-28 07:32:00 -04:00
fixed a crash
This commit is contained in:
parent
5b08baf5bf
commit
846196d048
@ -145,7 +145,9 @@ void addColorInString(std::string& str, const std::string& keyword,std::string c
|
||||
str.insert(pos,color2);
|
||||
pos+= color2.length();
|
||||
}
|
||||
else if(str.substr(pos -1,1) == " ")
|
||||
else
|
||||
{
|
||||
if(str.substr(pos -1,1) == " ")
|
||||
{
|
||||
str.insert(pos,color1);
|
||||
pos += color1.length();
|
||||
@ -153,6 +155,11 @@ void addColorInString(std::string& str, const std::string& keyword,std::string c
|
||||
str.insert(pos,color2);
|
||||
pos+= color2.length();
|
||||
}
|
||||
else
|
||||
{
|
||||
pos += keyword.length();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user