From: Arpad Ray Date: Wed, 17 Jul 2013 10:02:48 +0000 (+0100) Subject: Fix bug #62129 - rfc1867 crashes php even though turned off X-Git-Tag: php-5.5.1~7^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ba3234888dfbe14dadac7ac6c403a58bc1fdd220;p=php Fix bug #62129 - rfc1867 crashes php even though turned off Patch by gxd305 at gmail dot com --- diff --git a/NEWS b/NEWS index fff15a7440..4f6a111f51 100644 --- a/NEWS +++ b/NEWS @@ -75,6 +75,8 @@ PHP NEWS should warning). (Yasuo) . Fixed bug #49175 (mod_files.sh does not support hash bits). Patch by oorza2k5 at gmail dot com (Yasuo) + . Fixed bug #62129 (rfc1867 crashes php even though turned off). (gxd305 at + gmail dot com) - Sockets: . Implemented FR #63472 (Setting SO_BINDTODEVICE with socket_set_option). diff --git a/ext/session/session.c b/ext/session/session.c index 5af3ef2780..bbfe90e862 100644 --- a/ext/session/session.c +++ b/ext/session/session.c @@ -2246,8 +2246,11 @@ static PHP_MSHUTDOWN_FUNCTION(session) /* {{{ */ PHP_MSHUTDOWN(ps_mm) (SHUTDOWN_FUNC_ARGS_PASSTHRU); #endif - /* restore the orig callback */ - php_rfc1867_callback = php_session_rfc1867_orig_callback; + /* reset rfc1867 callbacks */ + php_session_rfc1867_orig_callback = NULL; + if (php_rfc1867_callback == php_session_rfc1867_callback) { + php_rfc1867_callback = NULL; + } ps_serializers[PREDEFINED_SERIALIZERS].name = NULL; memset(&ps_modules[PREDEFINED_MODULES], 0, (MAX_MODULES-PREDEFINED_MODULES)*sizeof(ps_module *));