diff options
author | Sara Golemon <pollita@php.net> | 2003-06-20 15:41:43 +0000 |
---|---|---|
committer | Sara Golemon <pollita@php.net> | 2003-06-20 15:41:43 +0000 |
commit | 4c52cf5f909cdce14173c56995187b60fd5dc15d (patch) | |
tree | a7828e54cd2e50a6541927214cd3c254b41e9011 | |
parent | c69d3959315806da31ea4cd209c71705f857889f (diff) | |
download | php-git-4c52cf5f909cdce14173c56995187b60fd5dc15d.tar.gz |
When skipping blank searchvals we should advance the corresponding replace hash as well
-rw-r--r-- | ext/standard/string.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ext/standard/string.c b/ext/standard/string.c index bfbd9d9f9d..46194042c9 100644 --- a/ext/standard/string.c +++ b/ext/standard/string.c @@ -3063,6 +3063,9 @@ static void php_str_replace_in_subject(zval *search, zval *replace, zval **subje convert_to_string(*search_entry); if (Z_STRLEN_PP(search_entry) == 0) { zend_hash_move_forward(Z_ARRVAL_P(search)); + if (Z_TYPE_P(replace) == IS_ARRAY) { + zend_hash_move_forward(Z_ARRVAL_P(replace)); + } continue; } |