httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r..@covalent.net
Subject Re: cvs commit: apache-2.0/src/main http_request.c
Date Mon, 23 Oct 2000 14:59:32 GMT
On Mon, 23 Oct 2000, Greg Stein wrote:

> On Mon, Oct 23, 2000 at 10:31:46AM -0000, rbb@locus.apache.org wrote:
> >...
> >   @@ -1462,6 +1463,19 @@
> >    
> >        new->output_filters  = r->connection->output_filters;
> >        new->input_filters   = r->connection->input_filters;
> 
> Why are we copying *connection* filters into the new *request* ??

We aren't copying the filters, we are setting the requests connection
filters.  Basically, this allows us to easily go to the connection filters
once we hit the end of the request.

> >   +    ap_add_output_filter("HTTP_HEADER", NULL, new, new->connection);
> >   +
> >   +    /* On an internal redirect, the redirect will take care of the headers,
> >   +     * so we have to remove the main-request's HTTP_HEADER filter
> >   +     */
> 
> Why is this? We should not have copied *any* of the request filters over to
> the new request. The new/redirected request should insert the
> core/chunked/header filters on its own, and we shouldn't have to worry about
> removing any.

This is a bit hairy.  The problem is that on internal redirects, we are
calling ap_finalize_protocol on the main request.  I personally think this
is wrong, but I wanted to make this work today, and ask if we should call
ap_finalize_protocol on the redirect instead of the main request.

> Any time that ap_remove_output_filter() is used, we should be suspicious
> about it. In this case, we should not have had to remove anything -- the
> problem is that we were copying filters over when we should not have been.

We should have made all of the assignments we made, we should just call
ap_finalize_request on the correct request, which we aren't doing
correctly right now.

Ryan


_______________________________________________________________________________
Ryan Bloom                        	rbb@apache.org
406 29th St.
San Francisco, CA 94131
-------------------------------------------------------------------------------


Mime
View raw message