You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by co...@apache.org on 2018/01/04 16:05:02 UTC

svn commit: r1820113 - in /httpd/httpd/trunk/server: listen.c mpm/prefork/prefork.c

Author: covener
Date: Thu Jan  4 16:05:02 2018
New Revision: 1820113

URL: http://svn.apache.org/viewvc?rev=1820113&view=rev
Log:
incorporate review comments from RĂ¼diger

Modified:
    httpd/httpd/trunk/server/listen.c
    httpd/httpd/trunk/server/mpm/prefork/prefork.c

Modified: httpd/httpd/trunk/server/listen.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/listen.c?rev=1820113&r1=1820112&r2=1820113&view=diff
==============================================================================
--- httpd/httpd/trunk/server/listen.c (original)
+++ httpd/httpd/trunk/server/listen.c Thu Jan  4 16:05:02 2018
@@ -1144,8 +1144,12 @@ AP_DECLARE_NONSTD(const char *) ap_set_a
                                                            void *dummy,
                                                            int flag)
 {
-   ap_accept_errors_nonfatal = flag;
-   return NULL;
+    const char *err = ap_check_cmd_context(cmd, GLOBAL_ONLY);
+    if (err != NULL) {
+        return err;
+    }
+    ap_accept_errors_nonfatal = flag;
+    return NULL;
 }
 
 AP_DECLARE_NONSTD(const char *) ap_set_receive_buffer_size(cmd_parms *cmd,

Modified: httpd/httpd/trunk/server/mpm/prefork/prefork.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/mpm/prefork/prefork.c?rev=1820113&r1=1820112&r2=1820113&view=diff
==============================================================================
--- httpd/httpd/trunk/server/mpm/prefork/prefork.c (original)
+++ httpd/httpd/trunk/server/mpm/prefork/prefork.c Thu Jan  4 16:05:02 2018
@@ -600,8 +600,8 @@ static void child_main(int child_num_arg
             /* resource shortage or should-not-occur occurred */
             clean_child_exit(APEXIT_CHILDSICK);
         }
-        else if (ap_accept_error_is_nonfatal(rc)) {
-            ap_log_error(APLOG_MARK, APLOG_DEBUG, rc, ap_server_conf,
+        if (ap_accept_error_is_nonfatal(status)) {
+            ap_log_error(APLOG_MARK, APLOG_DEBUG, status, ap_server_conf,
                     "accept() on client socket failed");
         }