blob: dc44625d8e0dd72d4c71007e6648704ce8cea8cb (
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
|
--TEST--
Bug #71839: Deserializing serialized SPLObjectStorage-Object can't access properties in PHP
--FILE--
<?php
class A extends SplObjectStorage {
protected $a = null;
public function __construct() {
$this->a = '123';
}
public function getA() {
return $this->a;
}
}
$serialized = serialize(new A());
$obj = unserialize($serialized);
var_dump($obj->getA());
?>
--EXPECT--
string(3) "123"
|