Fix str_replace
This commit is contained in:
@@ -96,7 +96,7 @@ std::string str_replace(const std::string & in, const std::string & needle, cons
|
|||||||
{
|
{
|
||||||
res += in.substr(pos, p2-pos);
|
res += in.substr(pos, p2-pos);
|
||||||
res += replacement;
|
res += replacement;
|
||||||
pos = p2 + replacement.size();
|
pos = p2 + needle.size();
|
||||||
}
|
}
|
||||||
if (!pos)
|
if (!pos)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user