felipe Wed Mar 12 19:18:42 2008 UTC
Added files: (Branch: PHP_5_3)
/php-src/ext/standard/tests/array bug42177.phpt
Modified files:
/php-src/ext/standard array.c
Log:
MFB: Fixed bug #42177 (Warning "array_merge_recursive(): recursion detected"
comes again...)
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/array.c?r1=1.308.2.21.2.37.2.26&r2=1.308.2.21.2.37.2.27&diff_format=u
Index: php-src/ext/standard/array.c
diff -u php-src/ext/standard/array.c:1.308.2.21.2.37.2.26
php-src/ext/standard/array.c:1.308.2.21.2.37.2.27
--- php-src/ext/standard/array.c:1.308.2.21.2.37.2.26 Fri Feb 22 13:28:40 2008
+++ php-src/ext/standard/array.c Wed Mar 12 19:18:42 2008
@@ -21,7 +21,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: array.c,v 1.308.2.21.2.37.2.26 2008/02/22 13:28:40 felipe Exp $ */
+/* $Id: array.c,v 1.308.2.21.2.37.2.27 2008/03/12 19:18:42 felipe Exp $ */
#include "php.h"
#include "php_ini.h"
@@ -2210,7 +2210,7 @@
if (recursive && zend_hash_find(dest,
string_key, string_key_len, (void **)&dest_entry) == SUCCESS) {
HashTable *thash = HASH_OF(*dest_entry);
- if ((thash && thash->nApplyCount > 1)
|| (*src_entry == *dest_entry && (Z_REFCOUNT_PP(dest_entry) % 2))) {
+ if ((thash && thash->nApplyCount > 1)
|| (*src_entry == *dest_entry && Z_ISREF_PP(dest_entry) &&
(Z_REFCOUNT_PP(dest_entry) % 2))) {
php_error_docref(NULL
TSRMLS_CC, E_WARNING, "recursion detected");
return 0;
}
http://cvs.php.net/viewvc.cgi/php-src/ext/standard/tests/array/bug42177.phpt?view=markup&rev=1.1
Index: php-src/ext/standard/tests/array/bug42177.phpt
+++ php-src/ext/standard/tests/array/bug42177.phpt
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php