httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Greg Stein <gst...@lyra.org>
Subject Re: cvs commit: apache-2.0/src/main http_protocol.c
Date Mon, 26 Jun 2000 20:03:19 GMT
Actually, that code is quite broken. I intended to get it fixed after the
filtering stuff was in (and ap_send_fd[_length] would move elsewhere).

The problem is that the file specified by "fd" might NOT be the same file as
referenced by r->finfo.

It also seems a bit wierd to test for APR_HAS_SENDFILE. It would be nicer to
check for iol->iol_sendfile to be non-NULL. That allows an APR
implementation to define a sendfile replacement, to use a real sendfile, or
to leave it blank (and Apache will fall back to a slower route).

Cheers,
-g

On Mon, Jun 26, 2000 at 05:25:55PM -0000, trawick@locus.apache.org wrote:
> trawick     00/06/26 10:25:54
> 
>   Modified:    src/main http_protocol.c
>   Log:
>   Fix the type of the 5th argument to iol_sendfile().
>   
>   Revision  Changes    Path
>   1.88      +1 -1      apache-2.0/src/main/http_protocol.c
>   
>   Index: http_protocol.c
>   ===================================================================
>   RCS file: /home/cvs/apache-2.0/src/main/http_protocol.c,v
>   retrieving revision 1.87
>   retrieving revision 1.88
>   diff -u -r1.87 -r1.88
>   --- http_protocol.c	2000/06/24 19:31:41	1.87
>   +++ http_protocol.c	2000/06/26 17:25:52	1.88
>   @@ -2240,7 +2240,7 @@
>     */
>    API_EXPORT(long) ap_send_fd(ap_file_t *fd, request_rec *r)
>    {
>   -    long len = r->finfo.size;
>   +    ap_size_t len = r->finfo.size;
>    #if APR_HAS_SENDFILE
>        if (!r->chunked) {
>    	ap_status_t rv;
>   
>   
>   

-- 
Greg Stein, http://www.lyra.org/

Mime
View raw message