|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #11617 crash when restoring references
Submitted: 2001-06-22 11:01 UTC Modified: 2001-06-24 13:16 UTC
From: zork at pablosoft dot com dot pl Assigned:
Status: Closed Package: Session related
PHP Version: 4.0 Latest CVS (2001-06-22) OS: Linux 2.2.16 (Cobalt Raq4)
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.
Block user comment
Status: Assign to:
Bug Type:
From: zork at pablosoft dot com dot pl
New email:
PHP Version: OS:


 [2001-06-22 11:01 UTC] zork at pablosoft dot com dot pl
There is still problem in serialize/unserialize mechanism  used to restore session variables(after closing #8676 bug which was supoused to correct the problem). Here is simplest script I can produce that does apache segfault on my machine:

class Cscreen {
	var $page;
	var $frames;

	function Cscreen() {
		$this -> frames = array();

class CError_handler {
	var $msg_error;
	function CError_handler() {
		$this -> msg_error = new CMessage();

class CConnection_Table {
	var $data;
	function CConnection_table() {
		$this -> data = array();
	function mconnect($message,&$object,$method) {
		$data[0] = &$object;
		$data[1] = $method;
		$this -> data[$message -> msg_id][] = $data;

class CMessage {
	var $data;
	var $msg_id;
	function CMessage($data = 0) {
		global $__CMSGID_NEXT;
		$this -> msg_id = $__CMSGID_NEXT++;
		$this -> data = $data;

function MCONNECT(&$message,&$obj_name,$method_name) {
	global $__connection_table;
	$__connection_table -> mconnect($message,$obj_name,$method_name);

$__connection_table = new CConnection_table;

$screen = new Cscreen();

$error_handler = new CError_handler($screen);
MCONNECT($error_handler -> msg_error,$screen,"fatal_error");
echo "done";


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2001-06-23 17:34 UTC]
Could you please try again? The fix wasn't ok, but now
it's been rewritten and should work.

If it still crashes, try to generate a gdb backtrace of
the crash. And thank you for helping!

 [2001-06-24 11:29 UTC] zork at pablosoft dot com dot pl
Tried, but php still changed. Maybe it is something with CVS (forgot to commit?), I've checked session.c revision and result was:

revision 1.213
date: 2001/06/21 18:46:25;  author: thies;  state: Exp;  lines: +31 -26

I've submitted this bug later.

 [2001-06-24 11:59 UTC]
And the GDB backtrace is where? Please include it.

 [2001-06-24 12:49 UTC] zork at pablosoft dot com dot pl
I've messed up something with my versions. Recompiled good and now it looks like it works fine. Sorry for confusion.


 [2001-06-24 13:16 UTC]
Closed then.

PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Sat Feb 04 05:03:38 2023 UTC