From: bugs dot php dot net at future dot shiny dot co dot il Operating system: FreeBSD PHP version: 4.3.10 PHP Bug Type: Scripting Engine problem Bug description: $this reference is bad during __wakeup
Description: ------------ This is a re-open of Bug #13968. I can still see the same issue happening with PHP 4.3.10. Just like the previous poster (in bug #13968), I cannot reproduce this with simple code. However, the general idea is this: class Base { var $resource = new Resource(); function __wakeup() { // In a saved session, the resource lost relevance, so we reopne it: $this->resource = open_resource(); // <-- this corrupts Thing's another_member } }; class Child extends Base { }; class Thing { var $member; var $another_member; // <-- when wakes up, this is equal to the Resource we open in Base's __wakeup. function Thing() { $this->member = new Child(); $this->another_member = 12345; } }; -- Edit bug report at http://bugs.php.net/?id=31313&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=31313&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=31313&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=31313&r=trysnapshot51 Fixed in CVS: http://bugs.php.net/fix.php?id=31313&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=31313&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=31313&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=31313&r=needscript Try newer version: http://bugs.php.net/fix.php?id=31313&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=31313&r=support Expected behavior: http://bugs.php.net/fix.php?id=31313&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=31313&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=31313&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=31313&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=31313&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=31313&r=dst IIS Stability: http://bugs.php.net/fix.php?id=31313&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=31313&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=31313&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=31313&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=31313&r=mysqlcfg