iliaa Mon Jun 11 15:08:43 2007 UTC Added files: (Branch: PHP_5_2) /php-src/ext/wddx/tests bug41527.phpt
Modified files: /php-src NEWS /php-src/ext/wddx wddx.c Log: Fixed bug #41527 (WDDX deserialize numeric string array key). http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.773&r2=1.2027.2.547.2.774&diff_format=u Index: php-src/NEWS diff -u php-src/NEWS:1.2027.2.547.2.773 php-src/NEWS:1.2027.2.547.2.774 --- php-src/NEWS:1.2027.2.547.2.773 Sat Jun 9 11:44:07 2007 +++ php-src/NEWS Mon Jun 11 15:08:43 2007 @@ -42,6 +42,8 @@ with ini_set()). (Tony, Dmitry) - Fixed bug #41555 (configure failure: regression caused by fix for #41265). (Jani) +- Fixed bug #41527 (WDDX deserialize numeric string array key). (php_lists + at realplain dot com, Ilia) - Fixed bug #41518 (file_exists() warns of open_basedir restriction on non-existent file). (Tony) - Fixed bug #39330 (apache2handler does not call shutdown actions before http://cvs.php.net/viewvc.cgi/php-src/ext/wddx/wddx.c?r1=1.119.2.10.2.16&r2=1.119.2.10.2.17&diff_format=u Index: php-src/ext/wddx/wddx.c diff -u php-src/ext/wddx/wddx.c:1.119.2.10.2.16 php-src/ext/wddx/wddx.c:1.119.2.10.2.17 --- php-src/ext/wddx/wddx.c:1.119.2.10.2.16 Sat May 5 15:14:56 2007 +++ php-src/ext/wddx/wddx.c Mon Jun 11 15:08:43 2007 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: wddx.c,v 1.119.2.10.2.16 2007/05/05 15:14:56 iliaa Exp $ */ +/* $Id: wddx.c,v 1.119.2.10.2.17 2007/06/11 15:08:43 iliaa Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -974,26 +974,7 @@ add_property_zval(ent2->data, ent1->varname, ent1->data); EG(scope) = old_scope; } else { - long l; - double d; - int varname_len = strlen(ent1->varname); - - switch (is_numeric_string(ent1->varname, varname_len, &l, &d, 0)) { - case IS_DOUBLE: - if (d > INT_MAX) { - goto bigint; - } - l = (long) d; - if (l != d) { - goto bigint; - } - case IS_LONG: - zend_hash_index_update(target_hash, l, &ent1->data, sizeof(zval *), NULL); - break; - default: -bigint: - zend_hash_update(target_hash,ent1->varname, varname_len + 1, &ent1->data, sizeof(zval *), NULL); - } + zend_symtable_update(target_hash, ent1->varname, strlen(ent1->varname)+1, &ent1->data, sizeof(zval *), NULL); } efree(ent1->varname); } else { http://cvs.php.net/viewvc.cgi/php-src/ext/wddx/tests/bug41527.phpt?view=markup&rev=1.1 Index: php-src/ext/wddx/tests/bug41527.phpt +++ php-src/ext/wddx/tests/bug41527.phpt -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php