php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #48387 ArrayObject and properties serialization
Submitted: 2009-05-25 15:46 UTC Modified: 2010-05-18 16:11 UTC
Votes:4
Avg. Score:4.5 ± 0.5
Reproduced:4 of 4 (100.0%)
Same Version:3 (75.0%)
Same OS:3 (75.0%)
From: david at grudl dot com Assigned: colder (profile)
Status: Wont fix Package: SPL related
PHP Version: 5.2.9 OS: *
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: david at grudl dot com
New email:
PHP Version: OS:

 

 [2009-05-25 15:46 UTC] david at grudl dot com
Description:
------------
In PHP 5.2.x there are not serialized any public/protected/private properies of ArrayObject descendants.



Reproduce code:
---------------
class Test extends ArrayObject
{
	public $var;
}

$test = new Test;
$test->var = 'hello';
$dolly = unserialize(serialize($test));
echo $dolly->var;

Expected result:
----------------
-> hello

Actual result:
--------------
none

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-02-28 10:55 UTC] seld@php.net
For what it's worth, the reproduce code works perfectly fine with php5.3.0
 [2010-04-18 00:17 UTC] jhominal at gmail dot com
I believe I had the same problem on PHP 5.2.13, on Debian Lenny (package provided 
by dotdeb)
 [2010-05-18 16:11 UTC] mike@php.net
-Status: Assigned +Status: Wont fix
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 18 18:01:28 2024 UTC