blob: 53bb5ba98d87f502bd3bec9cc6bb140d1fe30fba (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
--TEST--
Bug #43201 (Crash on using uninitialized vals and __get/__set)
--FILE--
<?php
class Foo {
function __get($k) {
return null;
}
function __set($k, $v) {
$this->$k = $v;
}
}
$c = new Foo();
$c->arr[0]["k"] = 1;
$c->arr[0]["k2"] = $ref;
for($cnt=0;$cnt<6;$cnt++) {
$ref = chop($undef);
$c->arr[$cnt]["k2"] = $ref;
}
echo "ok\n";
?>
--EXPECTF--
Notice: Indirect modification of overloaded property Foo::$arr has no effect in %sbug43201.php on line 13
Notice: Indirect modification of overloaded property Foo::$arr has no effect in %sbug43201.php on line 14
Notice: Undefined variable: ref in %sbug43201.php on line 14
Notice: Undefined variable: undef in %sbug43201.php on line 16
Notice: Indirect modification of overloaded property Foo::$arr has no effect in %sbug43201.php on line 17
Notice: Undefined variable: undef in %sbug43201.php on line 16
Notice: Indirect modification of overloaded property Foo::$arr has no effect in %sbug43201.php on line 17
Notice: Undefined variable: undef in %sbug43201.php on line 16
Notice: Indirect modification of overloaded property Foo::$arr has no effect in %sbug43201.php on line 17
Notice: Undefined variable: undef in %sbug43201.php on line 16
Notice: Indirect modification of overloaded property Foo::$arr has no effect in %sbug43201.php on line 17
Notice: Undefined variable: undef in %sbug43201.php on line 16
Notice: Indirect modification of overloaded property Foo::$arr has no effect in %sbug43201.php on line 17
Notice: Undefined variable: undef in %sbug43201.php on line 16
Notice: Indirect modification of overloaded property Foo::$arr has no effect in %sbug43201.php on line 17
ok
|