From fa77ba50a926cb4ea968f758b54510fa3e2f4bfc Mon Sep 17 00:00:00 2001 From: Amos Jeffries Date: Thu, 12 Aug 2010 21:37:14 +1200 Subject: [PATCH] Author: Stephen Thorne Bug 2936: NTLM-Authenticate 407 and Proxy-Connection: Close in same response. Squid default from the days of HTTP/1.0 was to close connections unless keep-alive was explicitly known. This changes the default to send keep-alive unless we have a good reason to close. --- src/client_side_reply.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/client_side_reply.cc b/src/client_side_reply.cc index fdf3185069..a32d7e40a2 100644 --- a/src/client_side_reply.cc +++ b/src/client_side_reply.cc @@ -1383,6 +1383,9 @@ clientReplyContext::buildReplyHeader() } else if (fdUsageHigh()&& !request->flags.must_keepalive) { debugs(88, 3, "clientBuildReplyHeader: Not many unused FDs, can't keep-alive"); request->flags.proxy_keepalive = 0; + } else if (request->http_ver.major == 1 && request->http_ver.minor == 1) { + debugs(88, 3, "clientBuildReplyHeader: Client is HTTP/1.1, send keep-alive, no overriding reasons not to"); + request->flags.proxy_keepalive = 1; } -- 2.47.2