1
0
mirror of https://github.com/php/php-src.git synced 2026-03-30 12:13:02 +02:00

Merge branch 'PHP-5.5' into PHP-5.6

This commit is contained in:
Nikita Popov
2014-01-04 01:29:15 +01:00
2 changed files with 26 additions and 4 deletions

26
Zend/tests/bug66286.phpt Normal file
View File

@@ -0,0 +1,26 @@
--TEST--
Bug #66286: Incorrect object comparison with inheritance
--FILE--
<?php
abstract class first {
protected $someArray = array();
}
class second extends first {
protected $someArray = array();
protected $someValue = null;
public function __construct($someValue) {
$this->someValue = $someValue;
}
}
$objFirst = new second('123');
$objSecond = new second('321');
var_dump ($objFirst == $objSecond);
?>
--EXPECT--
bool(false)

View File

@@ -1373,10 +1373,6 @@ static int zend_std_compare_objects(zval *o1, zval *o2 TSRMLS_DC) /* {{{ */
Z_OBJ_UNPROTECT_RECURSION(o1);
Z_OBJ_UNPROTECT_RECURSION(o2);
return 1;
} else {
Z_OBJ_UNPROTECT_RECURSION(o1);
Z_OBJ_UNPROTECT_RECURSION(o2);
return 0;
}
}
}