summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Zend/tests/gc_017.phpt4
-rw-r--r--Zend/tests/gc_033.phpt2
-rw-r--r--Zend/zend_gc.c14
3 files changed, 3 insertions, 17 deletions
diff --git a/Zend/tests/gc_017.phpt b/Zend/tests/gc_017.phpt
index a1a8c3eaf6..102c2b6bcb 100644
--- a/Zend/tests/gc_017.phpt
+++ b/Zend/tests/gc_017.phpt
@@ -31,12 +31,12 @@ $a->insert($c);
unset($a);
unset($b);
unset($c);
-var_dump(gc_collect_cycles() >= 7);
+var_dump(gc_collect_cycles());
echo "ok\n"
?>
--EXPECTF--
string(1) "%s"
string(1) "%s"
string(1) "%s"
-bool(true)
+int(4)
ok
diff --git a/Zend/tests/gc_033.phpt b/Zend/tests/gc_033.phpt
index 2db10196ad..1fd36976ad 100644
--- a/Zend/tests/gc_033.phpt
+++ b/Zend/tests/gc_033.phpt
@@ -27,4 +27,4 @@ for ($i=0; $i<9999; $i++) {
var_dump(gc_collect_cycles());
?>
--EXPECT--
-int(20001)
+int(10002)
diff --git a/Zend/zend_gc.c b/Zend/zend_gc.c
index 7ff1412ad6..199387643d 100644
--- a/Zend/zend_gc.c
+++ b/Zend/zend_gc.c
@@ -1183,10 +1183,6 @@ static int gc_collect_white(zend_refcounted *ref, uint32_t *flags, gc_stack *sta
ht = NULL;
if (!n) goto next;
while (!Z_REFCOUNTED_P(--end)) {
- /* count non-refcounted for compatibility ??? */
- if (Z_TYPE_P(zv) != IS_UNDEF) {
- count++;
- }
if (zv == end) goto next;
}
} else {
@@ -1200,9 +1196,6 @@ static int gc_collect_white(zend_refcounted *ref, uint32_t *flags, gc_stack *sta
GC_REF_SET_BLACK(ref);
GC_STACK_PUSH(ref);
}
- /* count non-refcounted for compatibility ??? */
- } else if (Z_TYPE_P(zv) != IS_UNDEF) {
- count++;
}
zv++;
}
@@ -1250,10 +1243,6 @@ static int gc_collect_white(zend_refcounted *ref, uint32_t *flags, gc_stack *sta
if (Z_REFCOUNTED_P(zv)) {
break;
}
- /* count non-refcounted for compatibility ??? */
- if (Z_TYPE_P(zv) != IS_UNDEF) {
- count++;
- }
if (p == end) goto next;
}
while (p != end) {
@@ -1268,9 +1257,6 @@ static int gc_collect_white(zend_refcounted *ref, uint32_t *flags, gc_stack *sta
GC_REF_SET_BLACK(ref);
GC_STACK_PUSH(ref);
}
- /* count non-refcounted for compatibility ??? */
- } else if (Z_TYPE_P(zv) != IS_UNDEF) {
- count++;
}
p++;
}