httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: cvs commit: apache-2.0/src/main http_protocol.c
Date Tue, 14 Nov 2000 06:55:16 GMT

> >Unfortunately, the Spec seems to say that a C-L on a HEAD response must be
> >the length of the actual data.  This problem is solved if the handlers
> >stop trying to deal with HEAD requests, but that also slows us down when
> >we try to serve HEAD requests.  
> >
> >I don't have a great answer for the problem yet, but am  I correct in how
> >I read the Spec?
> What about a HEAD on an SSI? If you don't send the data through the filters
> you can't know what the length of the data after SSI parsing is.

That's why I have the HTTP header filter setup to dump the data it gets,
and just send the headers.  The problem comes with handlers like
autoindex.  That handler tries to ignore the content-length, so it just
returns after sending the headers.  In Apache 1.3, that works fine.

In Apache 2.0, what is actually happening, is that the
ap_send_http_headers is a no-op, and when the handler returns, we end up
calling ap_finalize_request_protocol, which sends an EOS bucket down the
filter stack.  The C-L filter gets that bucket, computes a 0-length C-L,
and sets it, incorrectly.

What should happen, is all handlers should stop trying to handle HEAD, and
they should all just treat HEAD like GET, but that breaks legacy handlers,
which nobody wants to do.  :-(


Ryan Bloom               
406 29th St.
San Francisco, CA 94131

View raw message