httpd-test-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Orton <jor...@redhat.com>
Subject Re: svn commit: r111596 - /httpd/httpd/trunk/CHANGES /httpd/httpd/trunk/server/listen.c
Date Mon, 13 Dec 2004 12:26:17 GMT
On Sat, Dec 11, 2004 at 09:53:17AM -0000, Paul Querna wrote:
> Author: pquerna
> Date: Sat Dec 11 01:53:16 2004
> New Revision: 111596
> 
> URL: http://svn.apache.org/viewcvs?view=rev&rev=111596
> Log:
> * Add bits to use APR_TCP_DEFER_ACCEPT
> * Log Warnings when adding defer accept or an accept filter fails.

Hmmm - t/protocol/nntp-lite.t now hangs in the test suite on Linux.  I
suppose that doing a deferred accept is fundamentally incompatible with
protocols like NNTP where the client will connect() then read() a banner
line before writing any data.  Did this test work on FreeBSD before,
does anyone know?

> --- httpd/httpd/trunk/server/listen.c	(original)
> +++ httpd/httpd/trunk/server/listen.c	Sat Dec 11 01:53:16 2004
> @@ -164,7 +164,20 @@
>  #endif
>  #endif
>  #endif
> -    apr_socket_accept_filter(s, ACCEPT_FILTER_NAME, "");
> +    stat = apr_socket_accept_filter(s, ACCEPT_FILTER_NAME, "");
> +    if (stat != APR_SUCCESS && !APR_STATUS_IS_ENOTIMPL(stat)) {
> +        ap_log_perror(APLOG_MARK, APLOG_WARNING, stat, p,
> +                      "Failed to enable the '%s' Accept Filter",
> +                      ACCEPT_FILTER_NAME);
> +    }
> +#else
> +#ifdef APR_TCP_DEFER_ACCEPT
> +    stat = apr_socket_opt_set(s, APR_TCP_DEFER_ACCEPT, 1);   
> +    if (stat != APR_SUCCESS && !APR_STATUS_IS_ENOTIMPL(stat)) {
> +        ap_log_perror(APLOG_MARK, APLOG_WARNING, stat, p,
> +                              "Failed to enable APR_TCP_DEFER_ACCEPT");
> +    }
> +#endif
>  #endif
>  
>      server->sd = s;

Mime
View raw message