summaryrefslogtreecommitdiff
path: root/Zend/tests
diff options
context:
space:
mode:
Diffstat (limited to 'Zend/tests')
-rw-r--r--Zend/tests/bug68370.phpt18
1 files changed, 18 insertions, 0 deletions
diff --git a/Zend/tests/bug68370.phpt b/Zend/tests/bug68370.phpt
new file mode 100644
index 0000000000..25589bf455
--- /dev/null
+++ b/Zend/tests/bug68370.phpt
@@ -0,0 +1,18 @@
+--TEST--
+Bug #68370 "unset($this)" can make the program crash
+--FILE--
+<?php
+class C {
+ public function test() {
+ unset($this);
+ return get_defined_vars();
+ }
+}
+$c = new C();
+$x = $c->test();
+print_r($x);
+unset($c, $x);
+--EXPECTF--
+Array
+(
+)