httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s.@apache.org
Subject svn commit: r1180325 - in /httpd/httpd/trunk: CHANGES server/main.c
Date Sat, 08 Oct 2011 07:15:59 GMT
Author: sf
Date: Sat Oct  8 07:15:58 2011
New Revision: 1180325

URL: http://svn.apache.org/viewvc?rev=1180325&view=rev
Log:
Sort hooks twice, once before pre_config, once after ap_process_config_tree.
This fixes a regression with perl modules introduced by r1032002

PR: 45076
Submitted by: Torsten Foertsch <torsten foertsch gmx net>

Modified:
    httpd/httpd/trunk/CHANGES
    httpd/httpd/trunk/server/main.c

Modified: httpd/httpd/trunk/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/CHANGES?rev=1180325&r1=1180324&r2=1180325&view=diff
==============================================================================
--- httpd/httpd/trunk/CHANGES [utf-8] (original)
+++ httpd/httpd/trunk/CHANGES [utf-8] Sat Oct  8 07:15:58 2011
@@ -12,6 +12,9 @@ Changes with Apache 2.3.15
      PR 51714. [Stefan Fritsch, Jim Jagielski, Ruediger Pluem, Eric Covener,
      <lowprio20 gmail.com>]
 
+  *) core: Fix hook sorting with perl modules. PR: 45076. [Torsten Foertsch
+     <torsten foertsch gmx net>]
+
   *) core: Enforce LimitRequestFieldSize after multiple headers with the same
      name have been merged. [Stefan Fritsch]
 

Modified: httpd/httpd/trunk/server/main.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/main.c?rev=1180325&r1=1180324&r2=1180325&view=diff
==============================================================================
--- httpd/httpd/trunk/server/main.c (original)
+++ httpd/httpd/trunk/server/main.c Sat Oct  8 07:15:58 2011
@@ -618,6 +618,7 @@ int main(int argc, const char * const ar
     }
     apr_pool_cleanup_register(pconf, &ap_server_conf, ap_pool_cleanup_set_null,
                               apr_pool_cleanup_null);
+    /* sort hooks here to make sure pre_config hooks are sorted properly */
     apr_hook_sort_all();
 
     if (ap_run_pre_config(pconf, plog, ptemp) != OK) {
@@ -631,6 +632,12 @@ int main(int argc, const char * const ar
     if (rv == OK) {
         ap_fixup_virtual_hosts(pconf, ap_server_conf);
         ap_fini_vhost_config(pconf, ap_server_conf);
+        /*
+         * Sort hooks again because ap_process_config_tree may have add modules
+         * and hence hooks. This happens with mod_perl and modules written in
+         * perl.
+         */
+        apr_hook_sort_all();
 
         if (ap_run_check_config(pconf, plog, ptemp, ap_server_conf) != OK) {
             ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR, 0,
@@ -707,6 +714,7 @@ int main(int argc, const char * const ar
         }
         apr_pool_cleanup_register(pconf, &ap_server_conf,
                                   ap_pool_cleanup_set_null, apr_pool_cleanup_null);
+        /* sort hooks here to make sure pre_config hooks are sorted properly */
         apr_hook_sort_all();
 
         if (ap_run_pre_config(pconf, plog, ptemp) != OK) {
@@ -721,6 +729,12 @@ int main(int argc, const char * const ar
         }
         ap_fixup_virtual_hosts(pconf, ap_server_conf);
         ap_fini_vhost_config(pconf, ap_server_conf);
+        /*
+         * Sort hooks again because ap_process_config_tree may have add modules
+         * and hence hooks. This happens with mod_perl and modules written in
+         * perl.
+         */
+        apr_hook_sort_all();
 
         if (ap_run_check_config(pconf, plog, ptemp, ap_server_conf) != OK) {
             ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR, 0,



Mime
View raw message