httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Orton <>
Subject Re: [Bug 38070] - httpd returns status code 200 instead 304, but logged 304 in log.
Date Tue, 21 Feb 2006 14:56:03 GMT
On Tue, Feb 21, 2006 at 11:32:07AM +0000, Nick Kew wrote:
> On Tuesday 21 February 2006 09:49, wrote:
> > >The fix committed upstream prevents handling of conditional requests with
> > > a CGI script which outputs an explicit (albeit redundant) "Status: 200"
> > > header.  This would count as a regression so we would not include that
> > > patch as-is in a RHEL update.
> But the explicit 200 response is *not* redundant!  It is saying the CGI wants
> to return 200 rather than leave it to the server to return whatever is 
> appropriate (e.g. select 200 or 304 according to ap_meets_conditions).
> > >I've prepared a (simpler) alternative patch, which fixes the real issue
> > > and will make packages available for testing.
> Sure, it's a better fix to the particular example that was posted.  But that's
> only because that example was a misuse of the CGI "Status" header.
> Taken more generally, that patch breaks CGI by *preventing* it doing
> something that the CGI spec permits.

Well, interaction between CGI scripts and conditional request processing 
is not specified by the CGI spec (AFAICS anyway).  I think it's 
reasonable to perform conditional request processing even if the script 
sends an explicit "Status: 200" - indeed, that is exactly the behaviour 
that this code originally implemented.

The only actual bug is that r->status_line is respected over r->status 
as discussed just now in the other thread by Jeff - that is the bug that 
should be fixed, everything else is a workaround.


View raw message