diff --git a/plugins/include/string.inc b/plugins/include/string.inc index 01ad9d52..44ded07c 100755 --- a/plugins/include/string.inc +++ b/plugins/include/string.inc @@ -234,7 +234,7 @@ stock replace_all(string[], len, what[], with[]) new total_len = strlen(string); new temp_pos = 0 - while (replace(string[pos], len, what, with) != 0) + while (replace(string[pos], len - pos, what, with) != 0) { /* jump to position after replacement */ pos += with_len;