From cc85fdf510a26c149e4814c77d7958f4252af670 Mon Sep 17 00:00:00 2001 From: Antony Dovgal Date: Fri, 14 Oct 2005 21:50:46 +0000 Subject: [PATCH] add test for bug #34873 --- Zend/tests/bug34873.phpt | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 Zend/tests/bug34873.phpt diff --git a/Zend/tests/bug34873.phpt b/Zend/tests/bug34873.phpt new file mode 100644 index 0000000000..d8683c991f --- /dev/null +++ b/Zend/tests/bug34873.phpt @@ -0,0 +1,27 @@ +--TEST-- +bug #34873 (Segmentation Fault on foreach in object) +--FILE-- +var = array(); + } + + function test (){ + $cont = array(); + $cont["mykey"] = "myvalue"; + + foreach ($cont as $this->var['key'] => $this->var['value']) + var_dump($this->var['value']); + } +} +$myPwa = new Pwa(); +$myPwa->test(); + +echo "Done\n"; +?> +--EXPECT-- +string(7) "myvalue" +Done -- 2.50.1