mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
Fixed bug #62976 (Notice: could not be converted to int when comparing some builtin classes)
This commit is contained in:
parent
8afb848e18
commit
5dc2cef370
3 changed files with 7 additions and 6 deletions
2
NEWS
2
NEWS
|
@ -3,6 +3,8 @@ PHP NEWS
|
||||||
?? ??? 2012, PHP 5.3.16
|
?? ??? 2012, PHP 5.3.16
|
||||||
|
|
||||||
- Core:
|
- Core:
|
||||||
|
. Fixed bug #62976 (Notice: could not be converted to int when comparing
|
||||||
|
some builtin classes). (Laruence)
|
||||||
. Fixed bug (segfault while build with zts and GOTO vm-kind). (Laruence)
|
. Fixed bug (segfault while build with zts and GOTO vm-kind). (Laruence)
|
||||||
. Fixed bug #62955 (Only one directive is loaded from "Per Directory Values"
|
. Fixed bug #62955 (Only one directive is loaded from "Per Directory Values"
|
||||||
Windows registry). (aserbulov at parallels dot com)
|
Windows registry). (aserbulov at parallels dot com)
|
||||||
|
|
|
@ -1489,6 +1489,9 @@ ZEND_API int compare_function(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {
|
||||||
ret = compare_function(result, op1, op_free TSRMLS_CC);
|
ret = compare_function(result, op1, op_free TSRMLS_CC);
|
||||||
zend_free_obj_get_result(op_free TSRMLS_CC);
|
zend_free_obj_get_result(op_free TSRMLS_CC);
|
||||||
return ret;
|
return ret;
|
||||||
|
} else if (Z_TYPE_P(op1) == IS_OBJECT) {
|
||||||
|
ZVAL_LONG(result, 1);
|
||||||
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!converted) {
|
if (!converted) {
|
||||||
|
|
|
@ -20,9 +20,5 @@ var_dump($obj1 == $obj2);
|
||||||
===DONE===
|
===DONE===
|
||||||
--EXPECTF--
|
--EXPECTF--
|
||||||
Simple test comparing two objects with different compare callback handler
|
Simple test comparing two objects with different compare callback handler
|
||||||
|
bool(false)
|
||||||
Notice: Object of class X could not be converted to int in %s on line %d
|
===DONE===
|
||||||
|
|
||||||
Notice: Object of class DateTime could not be converted to int in %s on line %d
|
|
||||||
bool(true)
|
|
||||||
===DONE===
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue