* squid-2.3.STABLE1.add_content_length.patch * Sun Jan 16 05:52:06 CET 2000 Modified Files in squid/src client_side.c Add a Content-Length header on cache hits if none is present Index: squid/src/client_side.c diff -u squid/src/client_side.c:1.1.1.47.6.6 squid/src/client_side.c:1.1.1.47.6.7 --- squid/src/client_side.c:1.1.1.47.6.6 Sun Jan 16 04:01:57 2000 +++ squid/src/client_side.c Sun Jan 16 05:52:04 2000 @@ -1173,6 +1173,10 @@ httpHeaderDelById(hdr, HDR_CONNECTION); stringClean(&strConnection); } + /* Construct a Content-Length header if none is present */ + if (is_hit && !httpHeaderHas(hdr, HDR_CONTENT_LENGTH)) { + httpHeaderPutInt(hdr, HDR_CONTENT_LENGTH, contentLen(http->entry)); + } /* Handle Ranges */ if (request->range) clientBuildRangeHeader(http, rep);