From: Andrei Zmievski Date: Thu, 5 Oct 2006 18:23:19 +0000 (+0000) Subject: Increment replace count value for case-sensitive single char searches. X-Git-Tag: php-5.2.0RC5~2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e779c3aa3635f7e3ea15f13cb4320830c68bed4d;p=php Increment replace count value for case-sensitive single char searches. --- diff --git a/ext/standard/string.c b/ext/standard/string.c index 759528a232..29ef9c107c 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -3155,6 +3155,9 @@ PHPAPI int php_char_to_str_ex(char *str, uint len, char from, char *to, int to_l target += to_len; p++; s = p; + if (replace_count) { + *replace_count += 1; + } } if (s < e) { memcpy(target, s, (e - s));