From: Sterling Hughes Date: Wed, 16 May 2001 18:15:49 +0000 (+0000) Subject: Remove redundancy X-Git-Tag: PRE_GRANULAR_GARBAGE_FIX~392 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2d84ecbba82e29dfc377442f1623c9d94b25e99f;p=php Remove redundancy # And further fix problem ;) --- diff --git a/sapi/apache/mod_php4.c b/sapi/apache/mod_php4.c index f1f6c827c0..f07ac35418 100644 --- a/sapi/apache/mod_php4.c +++ b/sapi/apache/mod_php4.c @@ -295,10 +295,12 @@ static void php_apache_request_shutdown(void *dummy) static int php_apache_sapi_activate(SLS_D) { - request_rec *r = ((request_rec *) SG(server_context)); + request_rec *r; SLS_FETCH(); APLS_FETCH(); + r = (request_rec *) SG(server_context); + /* * For the Apache module version, this bit of code registers a cleanup * function that gets triggered when our request pool is destroyed. @@ -308,7 +310,7 @@ static int php_apache_sapi_activate(SLS_D) * memory. */ block_alarms(); - register_cleanup(((request_rec *) SG(server_context))->pool, NULL, php_apache_request_shutdown, php_request_shutdown_for_exec); + register_cleanup(r->pool, NULL, php_apache_request_shutdown, php_request_shutdown_for_exec); AP(in_request)=1; unblock_alarms();