Re: cvs: php4(PHP_4_3) / php.ini-dist php.ini-recommended /sapi/cgi cgi_main.c
| From: | Edin Kadribasic | Date: | Fri, 22 Nov 2002 11:14:28 +0000 |
| Subject: | Re: cvs: php4(PHP_4_3) / php.ini-dist php.ini-recommended /sapi/cgi cgi_main.c | ||
| References: | 1 | Groups: | php.cvs |
| Request: | Send a blank email to php-cvs+get-16546@lists.php.net to get a copy of this message | ||
On Fri, 22 Nov 2002, Sascha Schumann wrote:
> On Fri, 22 Nov 2002, Edin Kadribasic wrote:
>
> > On Fri, 22 Nov 2002, Sascha Schumann wrote:
> >
> > > > + if (rfc2616_headers && SG(sapi_headers).http_status_line) {
> > > > + len = sprintf(buf, "%s\r\n", SG(sapi_headers).http_status_line);
> > >
> > > So, if the user specifies that he wants to have
> > > rfc2616_headers, but http_status_line is not set, he gets the
> > > Status: line nevertheless?
> >
> > What should the correct behavior be. Send no default header (sending
> > status: amounts to this for a server that does not support it)? Send
> > "HTTP/1.0 200 OK"?
>
> The attached patch looks promising and restores the pre-4.3
> behaviour for the standard status 200 case. It also
> continues to provide a solution for non-200 status codes.
This *is* cleaner approach, but if we wanted to keep as close to pre-4.3
behaviour as possible I thing that "HTTP/1.0 %d Code\r\n" should be
replaced with SG(sapi_headers).http_status_line.
That way we also give user more freedom to try tweaks that might work for
their web server.
Edin