|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #21268 session_decode does corretly the job, but returns FALSE !!!
Submitted: 2002-12-29 11:06 UTC Modified: 2002-12-29 12:51 UTC
From: JeanFrederic at Loiseau dot org Assigned:
Status: Closed Package: Session related
PHP Version: 4.2.3 OS: Windows XP
Private report: No CVE-ID:
 [2002-12-29 11:06 UTC] JeanFrederic at Loiseau dot org
I believed that session_decode was not working, because it was always returning false, BUT it works... even if it returns FALSE !

Here is my sample code :



echo "test = ".$_SESSION['test']."<br><br>";

echo "buffer = ".$buffer."<br><br>";

echo "test = ".$_SESSION['test']."<br><br>";

if (session_decode($buffer)==FALSE) echo "<br>It returns FALSE !!!!<br>";

echo "test = ".$_SESSION['test']."<br><br>";


here is the ouput (after a REFRESH) :

test = 20
buffer = test|i:20;
test = 10
It returns FALSE !!!!
test = 20

It display "It returns FALSE", but $_SESSION['test'] is correctly initialized with 20 as it was...

Do I missed something ? or is it a bug ?

Thanks in advance,



Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-12-29 12:51 UTC]
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at
In case this was a documentation problem, the fix will show up soon at

In case this was a website problem, the change will show
up on the site and on the mirror sites in short time.
Thank you for the report, and for helping us make PHP better.

PHP Copyright © 2001-2015 The PHP Group
All rights reserved.
Last updated: Mon Nov 30 04:01:31 2015 UTC