cvs: php-src(PHP_5_1) / NEWS /ext/wddx wddx.c /ext/wddx/tests bug35410.phpt
| From: | Ilia Alshanetsky | Date: | Wed, 30 Nov 2005 18:10:20 +0000 |
| Subject: | cvs: php-src(PHP_5_1) / NEWS /ext/wddx wddx.c /ext/wddx/tests bug35410.phpt | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-35524@lists.php.net to get a copy of this message | ||
iliaa Wed Nov 30 13:10:20 2005 EDT
Added files: (Branch: PHP_5_1)
/php-src/ext/wddx/tests bug35410.phpt
Modified files:
/php-src NEWS
/php-src/ext/wddx wddx.c
Log:
Fixed bug #35410 (wddx_deserialize() doesn't handle large ints as keys
properly).
http://cvs.php.net/diff.php/php-src/NEWS?r1=1.2027.2.258&r2=1.2027.2.259&ty=u
Index: php-src/NEWS
diff -u php-src/NEWS:1.2027.2.258 php-src/NEWS:1.2027.2.259
--- php-src/NEWS:1.2027.2.258 Wed Nov 30 11:23:20 2005
+++ php-src/NEWS Wed Nov 30 13:10:16 2005
@@ -25,6 +25,8 @@
- Fixed bug #35422 (strtotime() does not parse times with UTC as timezone).
(Ilia)
- Fixed bug #35414 (strtotime() no longer works with ordinal suffix). (Ilia)
+- Fixed bug #35410 (wddx_deserialize() doesn't handle large ints as keys
+ properly). (Ilia)
- Fixed bug #35409 (undefined reference to 'rl_completion_matches'). (Jani)
- Fixed bug #35399 (Since fix of bug #35273 SOAP decoding of
soapenc:base64binary fails). (Dmitry)
http://cvs.php.net/diff.php/php-src/ext/wddx/wddx.c?r1=1.119.2.5&r2=1.119.2.6&ty=u
Index: php-src/ext/wddx/wddx.c
diff -u php-src/ext/wddx/wddx.c:1.119.2.5 php-src/ext/wddx/wddx.c:1.119.2.6
--- php-src/ext/wddx/wddx.c:1.119.2.5 Thu Oct 6 14:48:19 2005
+++ php-src/ext/wddx/wddx.c Wed Nov 30 13:10:19 2005
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: wddx.c,v 1.119.2.5 2005/10/06 18:48:19 rrichards Exp $ */
+/* $Id: wddx.c,v 1.119.2.6 2005/11/30 18:10:19 iliaa Exp $ */
#include "php.h"
@@ -1005,11 +1005,15 @@
switch (is_numeric_string(ent1->varname, strlen(ent1->varname), &l, &d, 0)) {
case IS_DOUBLE:
+ if (d > INT_MAX) {
+ goto bigint;
+ }
l = (long) d;
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, strlen(ent1->varname)+1,
&ent1->data, sizeof(zval *), NULL);
}
}
http://cvs.php.net/co.php/php-src/ext/wddx/tests/bug35410.phpt?r=1.1&p=1
Index: php-src/ext/wddx/tests/bug35410.phpt
+++ php-src/ext/wddx/tests/bug35410.phpt