php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #26093 access variable cause access violation
Submitted: 2003-11-03 05:27 UTC Modified: 2003-11-03 05:33 UTC
From: bruno dot faust at ig dot com dot br Assigned:
Status: Not a bug Package: Reproducible crash
PHP Version: 4.3.3 OS: XP SP1 latest
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: bruno dot faust at ig dot com dot br
New email:
PHP Version: OS:

 

 [2003-11-03 05:27 UTC] bruno dot faust at ig dot com dot br
Description:
------------
when y execute the php code i get "PHP has encountered an Access Violation at 010E28D2"

when y modify "=&" - second "=&" - to "=", thats all ok.

Reproduce code:
---------------
class name
{
	function load($name)
	{
		$file = "./name/" . $name . ".srlz";
		return unserialize(file_get_contents($file));
	}
}

$class_name =& new name;

$arr_estado =& $class_name->load("pais_estado");
$arr_estado =& $arr_estado[$_POST["usr_endereco"][$x]["pais_id"]];

print_r($arr_estado);

short example.
this example has not crash.
my pages is very longer....

Expected result:
----------------
Array
(
    [1] => Acre
    [2] => Alagoas
...
    [24] => Santa Catarina
    [25] => S?o Paulo
    [26] => Sergipe
    [27] => Tocantins
)

Actual result:
--------------
PHP has encountered an Access Violation at 010E28D2

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-11-03 05:33 UTC] moriyoshi@php.net
Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. Because of this, we hope you add your comments
to the existing bug instead.

Thank you for your interest in PHP.

Don't try to return anything other than a real variable by reference.

 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Fri May 29 21:01:25 2020 UTC