]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
* server/main.c (main): Bail out *before* signalling the server
authorWilliam A. Rowe Jr <wrowe@apache.org>
Tue, 21 Aug 2012 17:37:50 +0000 (17:37 +0000)
committerWilliam A. Rowe Jr <wrowe@apache.org>
Tue, 21 Aug 2012 17:37:50 +0000 (17:37 +0000)
  if the config is bad. (as per the claim in the docs!)

Backports: r1328345
Submitted by: jorton
Reviewed by: rjung, trawick, wrowe

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x@1375680 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
STATUS
server/main.c

diff --git a/CHANGES b/CHANGES
index 4db8d39c04a62adc75ea7321f07f931a6de5e5b4..4131948d5f99883616733103f458adb24c6c6597 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -10,6 +10,9 @@ Changes with Apache 2.2.23
      possible XSS for a site where untrusted users can upload files to
      a location with MultiViews enabled. [Niels Heinen <heinenn google.com>]
 
+  *) core: Prevent "httpd -k restart" from killing server in presence of
+     config error. [Joe Orton]
+
   *) mod_ssl: when compiled against OpenSSL 1.0.1 or later, allow explicit
      control of TLSv1.1 and TLSv1.2 through the SSLProtocol directive,
      adding TLSv1.1 and TLSv1.2 support by default given 'SSLProtocol All'.
diff --git a/STATUS b/STATUS
index 5a0eb83d204b480f66d1154cf6ad6feb93809571..3a76f4e6c24f785e34c823ca7f7c6eb0906ddec6 100644 (file)
--- a/STATUS
+++ b/STATUS
@@ -122,14 +122,6 @@ PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
      2.2.x patch: trunk patch applies
      +1: rjung, trawick, wrowe
 
-   * core: Bail out *before* signalling the server if the config is bad.
-     (as per the claim in the docs!) Prevents "httpd -k restart" from
-     killing server in presence of config error.
-     trunk patch: http://svn.apache.org/viewvc?view=revision&revision=1328345
-     2.4.x patch: http://svn.apache.org/viewvc?view=revision&revision=1331847
-     2.2.x patch: trunk patch applies
-     +1: rjung, trawick, wrowe
-
 PATCHES PROPOSED TO BACKPORT FROM TRUNK:
   [ New proposals should be added at the end of the list ]
 
index 224a10ef77abd794ce0f86f7fd7ea89d2f3db0f8..0892b1f9ed0d0dfa650c168af22cc3712d1527c9 100644 (file)
@@ -661,6 +661,11 @@ int main(int argc, const char * const argv[])
         }
     }
 
+    /* If our config failed, deal with that here. */
+    if (rv != OK) {
+        destroy_and_exit_process(process, 1);
+    }
+
     signal_server = APR_RETRIEVE_OPTIONAL_FN(ap_signal_server);
     if (signal_server) {
         int exit_status;
@@ -670,11 +675,6 @@ int main(int argc, const char * const argv[])
         }
     }
 
-    /* If our config failed, deal with that here. */
-    if (rv != OK) {
-        destroy_and_exit_process(process, 1);
-    }
-
     apr_pool_clear(plog);
 
     if ( ap_run_open_logs(pconf, plog, ptemp, server_conf) != OK) {