Re: 4.4.6RC1
| From: | Matt Wilmas | Date: | Wed, 21 Feb 2007 08:08:44 +0000 |
| Subject: | Re: 4.4.6RC1 | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-28107@lists.php.net to get a copy of this message | ||
Hi Derick,
Attached is a very simple patch for Bug #40115 (possibly wrong numeric
string comparison caused by overflow) if you want to fix it in 4.4. :-)
Matt
----- Original Message -----
From: "Derick Rethans"
Sent: Tuesday, February 20, 2007
> Hello!
>
> there is a critical issues in PHP 4.4.5:
> - when register_globals = On, sessions don't work correctly (segfaults).
>
> Because of this I'd like to release a 4.4.6 soon with this fixes. As
> there is also an upgrade to pcre 7.0 we'd need atleast one RC, which I
> plan to release on Thursday.
>
> Any opinions?
>
> regards,
> Derick
Index: zend_operators.c =================================================================== RCS file: /repository/Zend/Attic/zend_operators.c,v retrieving revision 1.129.2.10.2.2 diff -u -r1.129.2.10.2.2 zend_operators.c --- zend_operators.c 3 Oct 2006 17:55:40 -0000 1.129.2.10.2.2 +++ zend_operators.c 18 Jan 2007 10:53:59 -0000 @@ -1737,8 +1737,7 @@ result->value.lval = ZEND_NORMALIZE_BOOL(result->value.dval); result->type = IS_LONG; } else { /* they both have to be long's */ - result->value.lval = lval1 - lval2; - result->value.lval = ZEND_NORMALIZE_BOOL(result->value.lval); + result->value.lval = lval1 > lval2 ? 1 : (lval1 < lval2 ? -1 : 0); result->type = IS_LONG; } } else {
Index: zend_operators.c =================================================================== RCS file: /repository/Zend/Attic/zend_operators.c,v retrieving revision 1.129.2.10.2.2 diff -u -r1.129.2.10.2.2 zend_operators.c --- zend_operators.c 3 Oct 2006 17:55:40 -0000 1.129.2.10.2.2 +++ zend_operators.c 18 Jan 2007 10:53:59 -0000 @@ -1737,8 +1737,7 @@ result->value.lval = ZEND_NORMALIZE_BOOL(result->value.dval); result->type = IS_LONG; } else { /* they both have to be long's */ - result->value.lval = lval1 - lval2; - result->value.lval = ZEND_NORMALIZE_BOOL(result->value.lval); + result->value.lval = lval1 > lval2 ? 1 : (lval1 < lval2 ? -1 : 0); result->type = IS_LONG; } } else {