Annotation of embedaddon/php/ext/standard/tests/array/bug34227.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: Bug #34277 (array_filter() crashes with references and objects)
3: --FILE--
4: <?php
5:
6: class C
7: {
8: function m1()
9: {
10: $this->m2();
11: }
12:
13: function m2()
14: {
15: $this->m3();
16: }
17:
18: function m3()
19: {
20: $this->m4();
21: }
22:
23: function m4()
24: {
25: $this->m5();
26: }
27:
28: function m5()
29: {
30: $this->m6();
31: }
32:
33: function m6()
34: {
35: $this->m7();
36: }
37:
38: function m7()
39: {
40: $this->m8();
41: }
42:
43: function m8()
44: {
45: $this->m9();
46: }
47:
48: function m9()
49: {
50: $this->m10();
51: }
52:
53: function m10()
54: {
55: $this->m11(1, 2, 3, 4, 5, 6, 7, 8, 9, 10);
56: }
57:
58: function m11($a1, $a2, $a3, $a4, $a5, $a6, $a7, $a8, $a9, $a10)
59: {
60: $arr = explode('a', 'b');
61: }
62: }
63:
64: function f($str)
65: {
66: $obj = new C;
67: $obj->m1();
68: return TRUE;
69: }
70:
71: function p5($a1, $a2, $a3, $a4, $a5, $a6, $a7, $a8, $a9, $a10, $a11, $a12)
72: {
73: $ret = array_filter(array(0), 'f');
74: }
75:
76: function p4()
77: {
78: p5(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12);
79: }
80:
81: function p3()
82: {
83: p4();
84: }
85:
86: function p2()
87: {
88: p3();
89: }
90:
91: function p1()
92: {
93: p2();
94: }
95:
96: p1();
97: echo "ok\n";
98: ?>
99: --EXPECT--
100: ok
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>