]> git.ipfire.org Git - thirdparty/squid.git/commit
Send chunked responses if body size is unknown.
authorAlex Rousskov <rousskov@measurement-factory.com>
Tue, 24 Aug 2010 00:02:15 +0000 (18:02 -0600)
committerAlex Rousskov <rousskov@measurement-factory.com>
Tue, 24 Aug 2010 00:02:15 +0000 (18:02 -0600)
commit4ad606098377d311d430be87556c6fd52f0ab8e1
treeb77e2cff226e688cd3e58a8dbeed5408a66df20c
parent922b9825a31d6cbd4c3b1738d0c45cda0efd9373
Send chunked responses if body size is unknown.

Apply HTTP chunked transfer encoding to the response body sent to client
if all of the following conditions are met:

* client claims HTTP version 1.1 or later support
* response does not have a Content-Length header already
* response does not use multipart/byteranges encoding
* connection is persistent

If we decide to send chunked reply, chunked_reply flag is set. Chunked
encoding is done in ClientSocketContext::packChunk(). The last-chunk
is sent only when clientReplyContext complete flag is set.

This change helps keep client-side connections persistent.
compat/types.h
src/client_side.cc
src/client_side.h
src/client_side_reply.cc
src/structs.h