Add "AcceptErrorsNonFatal" directive

This tweaks accept() failure processing by having ap_unixd_accept
pass more errors up, and having the MPM's check against a macro
to see if they are in a whitelist of non ENETDOWN/EMFILE kind 
of potential process-wide errors.

Default behavior is still to exit.

edit: MMN bump in 1820099.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1820098 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Eric Covener
2018-01-04 15:10:45 +00:00
parent 3a216c2776
commit 98e9503120
9 changed files with 97 additions and 3 deletions

View File

@ -320,6 +320,12 @@ AP_DECLARE(apr_status_t) ap_unixd_accept(void **accepted, ap_listen_rec *lr,
if (APR_STATUS_IS_EINTR(status)) {
return status;
}
/* Let the caller handle slightly more varied return values */
if (lr->use_specific_errors && ap_accept_error_is_nonfatal(status)) {
return status;
}
/* Our old behaviour here was to continue after accept()
* errors. But this leads us into lots of troubles
* because most of the errors are quite fatal. For