]> granicus.if.org Git - php/commitdiff
Remove redundancy
authorSterling Hughes <sterling@php.net>
Wed, 16 May 2001 18:15:49 +0000 (18:15 +0000)
committerSterling Hughes <sterling@php.net>
Wed, 16 May 2001 18:15:49 +0000 (18:15 +0000)
# And further fix problem ;)

sapi/apache/mod_php4.c

index f1f6c827c0f00d0badaa9eb2cc2d6f4a932def05..f07ac3541818d8023532837cf63def205cc803bb 100644 (file)
@@ -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();