#35779 [Opn->Fbk]: private members are not serialized properly
| From: | tony2001@php.net | Date: | Thu, 22 Dec 2005 21:41:17 +0000 |
| Subject: | #35779 [Opn->Fbk]: private members are not serialized properly | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-90902@lists.php.net to get a copy of this message | ||
ID: 35779
Updated by: tony2001@php.net
Reported By: romdisc at gmx dot net
-Status: Open
+Status: Feedback
Bug Type: Session related
Operating System: Linux-2.6.8
PHP Version: 5.1.1
New Comment:
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves.
A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external
resources such as databases, etc.
If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.
Previous Comments:
------------------------------------------------------------------------
[2005-12-22 22:39:33] romdisc at gmx dot net
Description:
------------
Hello,
** my system: debian apache2 php module 5.0.5-3
this is a variation of bug 26737!
My superclass of ProductItem implements a private members. Those are
not covered with the fix of bug 26737.
Last 2 lines (__vat, __vatMode) of 'Actual Result' are inherited from
superclass. __wakeup() ignores given values if present.
Here is snaps:hot from sess_file:
O:11:"ProductItem":4:{s:13:"^@*^@__quantity";i:5;s:5:"__vat";N;
s:9:"__vatMode";R:3;s:17:"^@ProductItem^@__id";i:5044;}
Reproduce code:
---------------
// investigate your session file
Expected result:
----------------
ProductItem Object
(
[__id:private] => 5044
[__product:private] =>
[__vat:private] =>
[__vatMode:private] =>
[__quantity:protected] => 5
)
Actual result:
--------------
ProductItem Object
(
[__id:private] => 5044
[__product:private] =>
[__vat:private] =>
[__vatMode:private] =>
[__quantity:protected] => 5
[__vat] =>
[__vatMode] =>
)
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=35779&edit=1