php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #16070 Set any variable after error occur..
Submitted: 2002-03-14 10:01 UTC Modified: 2002-03-14 14:36 UTC
Votes:1
Avg. Score:4.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: rusek at ccs dot cz Assigned:
Status: Not a bug Package: Variables related
PHP Version: 4.1.2 OS: Windows, Unix BSD, Linux RedHat
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: rusek at ccs dot cz
New email:
PHP Version: OS:

 

 [2002-03-14 10:01 UTC] rusek at ccs dot cz
<?PHP
/* reported by Milan Rusek, rusek@ccs.cz
 */
 
echo 'Before: '.(isset($retval)?'set':'not set'); 
echo "\n";

$retval = @unserialize('blablabla'); // FAIL !!!!
	// variable $retval it should not be set!!

echo 'After : '.(isset($retval)?'set':'not set'); 
echo "\n";
echo "It must be same results!\n";


/* ----------------------------------------------
 * I have found only one solution, but I mean 
 * that it is very small powerful:

$retval = @unserialize('blablabla');
if (serialize($retval) == 'blablabla')
{
	// is ok.
}
else
{
	// is failed.
}

 * Do you have some better solution?
 */
?>

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-03-14 14:36 UTC] sniper@php.net
This is not a bug. Please double-check the documentation available
at http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 18 12:01:28 2024 UTC