Changeset 1985
- Timestamp:
- 09/06/2007 11:24:20 AM (12 months ago)
- Location:
- branches/lighttpd-1.4.x
- Files:
-
- 3 modified
-
NEWS (modified) (1 diff)
-
src/connections.c (modified) (1 diff)
-
tests/mod-redirect.t (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/lighttpd-1.4.x/NEWS
r1983 r1985 8 8 * fixed forwarding a SIGINT and SIGHUP when using max-workers (#902) 9 9 * fixed FastCGI header overrun in mod_fastcgi (reported by mattias@secweb.se) 10 * fixed hanging redirects with keep-alive due to missing 11 "Content-Length: 0" headers 10 12 11 13 -
branches/lighttpd-1.4.x/src/connections.c
r1946 r1985 538 538 con->http_status == 304) { 539 539 /* no Content-Body, no Content-Length */ 540 } else if (qlen > 0) { 540 } else if (qlen >= 0) { 541 /* qlen = 0 is important for Redirects (301, ...) as they MAY have 542 * a content. Browsers are waiting for a Content otherwise 543 */ 541 544 buffer_copy_off_t(srv->tmp_buf, chunkqueue_length(con->write_queue)); 542 545 -
branches/lighttpd-1.4.x/tests/mod-redirect.t
r1374 r1985 9 9 use strict; 10 10 use IO::Socket; 11 use Test::More tests => 6;11 use Test::More tests => 7; 12 12 use LightyTest; 13 13 … … 24 24 $t->{RESPONSE} = [ { 'HTTP-Protocol' => 'HTTP/1.0', 'HTTP-Status' => 301, 'Location' => 'http://localhost:'.$tf->{PORT}.'/' } ]; 25 25 ok($tf->handle_http($t) == 0, 'external redirect'); 26 27 $t->{REQUEST} = ( <<EOF 28 GET /redirect/ HTTP/1.0 29 Host: vvv.example.org 30 EOF 31 ); 32 $t->{RESPONSE} = [ { 'HTTP-Protocol' => 'HTTP/1.0', 'HTTP-Status' => 301, 'Location' => 'http://localhost:'.$tf->{PORT}.'/', 'Content-Length' => '0' } ]; 33 ok($tf->handle_http($t) == 0, 'external redirect should have a Content-Length: 0'); 26 34 27 35 $t->{REQUEST} = ( <<EOF

