]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
fix 2.2.21 induced sorting bug
authorJim Jagielski <jim@apache.org>
Sun, 9 Oct 2011 12:35:53 +0000 (12:35 +0000)
committerJim Jagielski <jim@apache.org>
Sun, 9 Oct 2011 12:35:53 +0000 (12:35 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x@1180594 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
STATUS
server/main.c

diff --git a/CHANGES b/CHANGES
index 624fc88073147b36904403a932b29ae0a8c0544f..ea8fb94352d690dc29bcdd325683ec580352e0ec 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -6,6 +6,9 @@ Changes with Apache 2.2.22
      specification, preventing unexpected expansion of target URLs in
      some reverse proxy configurations.  [Joe Orton]
 
+  *) core: Fix hook sorting for perl modules, a regression introduced in
+     2.2.21. PR: 45076. [Torsten Foertsch <torsten foertsch gmx net>]
+
   *) Fix a regression introduced by the CVE-2011-3192 byterange fix in 2.2.20:
      A range of '0-' will now return 206 instead of 200. PR 51878.
      [Jim Jagielski]
diff --git a/STATUS b/STATUS
index 02c606a8ee3400e11367d479f49c403bd7532941..ddea6331a321d059ccd5965539c0da20135d1b24 100644 (file)
--- a/STATUS
+++ b/STATUS
@@ -92,11 +92,6 @@ RELEASE SHOWSTOPPERS:
 PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
   [ start all new proposals below, under PATCHES PROPOSED. ]
 
-  * core: Fix hook sorting for perl modules, a regression introduced in 2.2.21
-    Trunk patch: http://svn.apache.org/viewvc?view=revision&revision=1180325
-    2.2.x patch: http://people.apache.org/~sf/2.2_hook_sorting.diff
-    +1: sf, trawick, jim
-
 
 PATCHES PROPOSED TO BACKPORT FROM TRUNK:
   [ New proposals should be added at the end of the list ]
index 04ed6c78d4731334c04d1b12a834d47c013ed16b..224a10ef77abd794ce0f86f7fd7ea89d2f3db0f8 100644 (file)
@@ -633,6 +633,7 @@ int main(int argc, const char * const argv[])
     if (!server_conf) {
         destroy_and_exit_process(process, 1);
     }
+    /* 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) {
@@ -646,6 +647,12 @@ int main(int argc, const char * const argv[])
     if (rv == OK) {
         ap_fixup_virtual_hosts(pconf, server_conf);
         ap_fini_vhost_config(pconf, server_conf);
+        /*
+         * Sort hooks again because ap_process_config_tree may have added
+         * modules and hence hooks. This happens with mod_perl and modules
+         * written in perl.
+         */
+        apr_hook_sort_all();
 
         if (configtestonly) {
             ap_run_test_config(pconf, server_conf);
@@ -704,6 +711,7 @@ int main(int argc, const char * const argv[])
         if (!server_conf) {
             destroy_and_exit_process(process, 1);
         }
+        /* 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) {
@@ -718,6 +726,12 @@ int main(int argc, const char * const argv[])
         }
         ap_fixup_virtual_hosts(pconf, server_conf);
         ap_fini_vhost_config(pconf, server_conf);
+        /*
+         * Sort hooks again because ap_process_config_tree may have added
+         * modules and hence hooks. This happens with mod_perl and modules
+         * written in perl.
+         */
+        apr_hook_sort_all();
         apr_pool_clear(plog);
         if (ap_run_open_logs(pconf, plog, ptemp, server_conf) != OK) {
             ap_log_error(APLOG_MARK, APLOG_STARTUP |APLOG_ERR,