#23757 [NEW]: name of session variable gets corrupted
| From: | tony at marston-home dot demon dot co dot uk | Date: | Thu, 22 May 2003 16:48:36 +0000 |
| Subject: | #23757 [NEW]: name of session variable gets corrupted | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-40200@lists.php.net to get a copy of this message | ||
From: tony at marston-home dot demon dot co dot uk
Operating system: WindowsXP
PHP version: 4.3.2RC4
PHP Bug Type: Session related
Bug description: name of session variable gets corrupted
In script #1 I want to store values in $_SESSION so that they will be
available to script #2, so I use the script name as the key, as in
$_SESSION['option_enq.php'] = 'whatever';
When script #2 (option_enq.php) starts up it does session_start() then
looks in $_SESSION for a value with its name. However, as of 4.3.2RC4 it
cannot find it! I examined the contents of $_SESSION with my debugger and
it showed me the key name had been changed to ';option_enq.php' - a
semi-colon had been added in front.
I ran this through several times and I checked that before leaving the
first script that $_SESSION contained the entry without the leading ';',
but as soon as script #2 looks at the session array the name has been
corrupted.
Here is a copy of the session data file:
expectedscript|s:14:"option_enq.php";prog_stack|a:1:{i:0;s:23:"/xample/option_list.php";}option_list.php|a:8:{s:12:"script_count";i:2;s:5:"where";N;s:9:"selection";N;s:6:"pageno";i:1;s:7:"orderby";N;s:5:"order";N;s:6:"search";N;s:9:"pkeyarray";a:10:{i:1;a:1:{s:9:"option_id";s:8:"ALBATROS";}i:2;a:1:{s:9:"option_id";s:8:"ALIGATOR";}i:3;a:1:{s:9:"option_id";s:8:"BARACUDA";}i:4;a:1:{s:9:"option_id";s:6:"BUMBLE";}i:5;a:1:{s:9:"option_id";s:8:"CHINCHIL";}i:6;a:1:{s:9:"option_id";s:8:"CROCODIL";}i:7;a:1:{s:9:"option_id";s:8:"DINOSAUR";}i:8;a:1:{s:9:"option_id";s:8:"DUCKBILL";}i:9;a:1:{s:9:"option_id";s:8:"ELEPHANT";}i:10;a:1:{s:9:"option_id";s:3:"EMU";}}}script_start|d:1053620791.8506410121917724609375;option_enq.php|a:2:{s:9:"selection";s:22:"(option_id='ALBATROS')";s:14:"orig_selection";s:22:"(option_id='ALBATROS')";}
--
Edit bug report at http://bugs.php.net/?id=23757&edit=1
--
Try a CVS snapshot: http://bugs.php.net/fix.php?id=23757&r=trysnapshot
Fixed in CVS: http://bugs.php.net/fix.php?id=23757&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=23757&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=23757&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=23757&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=23757&r=support
Expected behavior: http://bugs.php.net/fix.php?id=23757&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=23757&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=23757&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=23757&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=23757&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=23757&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=23757&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=23757&r=gnused