php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login

Patch php-5.4.11-session-reset-global-var-in-shutdown for Session related Bug #62129

Patch version 2013-01-27 05:03 UTC

Return to Bug #62129 | Download this patch
Patch Revisions:

Developer: gxd305@gmail.com

diff -cr php-5.4.11/ext/session/session.c php-5.4.11-2/ext/session/session.c
*** php-5.4.11/ext/session/session.c	2013-01-16 15:10:30.000000000 +0800
--- php-5.4.11-2/ext/session/session.c	2013-01-20 15:22:17.427613455 +0800
***************
*** 2224,2229 ****
--- 2224,2235 ----
  	ps_serializers[PREDEFINED_SERIALIZERS].name = NULL;
  	memset(&ps_modules[PREDEFINED_MODULES], 0, (MAX_MODULES-PREDEFINED_MODULES)*sizeof(ps_module *));
  
+ 	// reset the callback pointer to null
+ 	php_session_rfc1867_orig_callback = NULL;
+ 	if(php_rfc1867_callback == php_session_rfc1867_callback) {
+ 		php_rfc1867_callback = NULL;
+ 	}
+ 
  	return SUCCESS;
  }
  /* }}} */
 
PHP Copyright © 2001-2014 The PHP Group
All rights reserved.
Last updated: Sat Apr 19 22:02:16 2014 UTC