Hi folks,
I believe there's an issue with the SessionHandler implementation and
the way the destroy handler is invoked when using
session_regenerate_id(TRUE)
Using latest stable Gentoo PHP 5.4.6 but as far as I could tell the C
code source for this part hasn't since been touched up to master.
The following code generates a warning :
$handler = new SessionHandler();
session_set_save_handler($handler, TRUE); // or FALSE, doesn't matter
session_start()
;
session_regenerate_id(TRUE);
//session_write_close();
PHP Warning: Unknown: Parent session handler is not open in Unknown on line 0
The call to session_write_close()
just adds a proper backtrace.
The problem seems to come from using the global "mod_user_is_open" in
the PS_SANITY_CHECK_IS_OPEN macro (in ext/session/mod_user_class.c).
Any reason "session_status" isn't checked instead ?
Can anyone confirm ?
Thank you
Hey:
could you please open a bug at bugs.php.net for that?
thanks
Hi folks,
I believe there's an issue with the SessionHandler implementation and
the way the destroy handler is invoked when using
session_regenerate_id(TRUE)Using latest stable Gentoo PHP 5.4.6 but as far as I could tell the C
code source for this part hasn't since been touched up to master.The following code generates a warning :
$handler = new SessionHandler();
session_set_save_handler($handler, TRUE); // or FALSE, doesn't matter
session_start()
;
session_regenerate_id(TRUE);//session_write_close();
PHP Warning: Unknown: Parent session handler is not open in Unknown on line 0
The call to
session_write_close()
just adds a proper backtrace.The problem seems to come from using the global "mod_user_is_open" in
the PS_SANITY_CHECK_IS_OPEN macro (in ext/session/mod_user_class.c).
Any reason "session_status" isn't checked instead ?Can anyone confirm ?
Thank you
--
--
Laruence Xinchen Hui
http://www.laruence.com/
Done :
https://bugs.php.net/bug.php?id=63379
----- Mail original -----
De : Laruence laruence@php.net
À : dabo avatar2004-php@yahoo.fr
Cc : "internals@lists.php.net" internals@lists.php.net; Arpad Ray arpad@php.net
Envoyé le : Dimanche 28 octobre 2012 11h24
Objet : Re: [PHP-DEV] Warning when using session_regenerate_id(TRUE) with a SessionHandler
Hey:
could you please open a bug at bugs.php.net for that?
thanks
Hi folks,
I believe there's an issue with the SessionHandler implementation and
the way the destroy handler is invoked when using
session_regenerate_id(TRUE)Using latest stable Gentoo PHP 5.4.6 but as far as I could tell the C
code source for this part hasn't since been touched up to master.The following code generates a warning :
$handler = new SessionHandler();
session_set_save_handler($handler, TRUE); // or FALSE, doesn't matter
session_start()
;
session_regenerate_id(TRUE);//session_write_close();
PHP Warning: Unknown: Parent session handler is not open in Unknown on line 0
The call to
session_write_close()
just adds a proper backtrace.The problem seems to come from using the global "mod_user_is_open" in
the PS_SANITY_CHECK_IS_OPEN macro (in ext/session/mod_user_class.c).
Any reason "session_status" isn't checked instead ?Can anyone confirm ?
Thank you
--
--
Laruence Xinchen Hui
http://www.laruence.com/