From c4748069b9309ace155e0c73da0c9441784a4773 Mon Sep 17 00:00:00 2001 From: finaldie Date: Thu, 19 Dec 2013 15:54:22 +0000 Subject: [PATCH] Fix an further keepalive issue when responding with 204 --- proxy/http/HttpTransact.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/proxy/http/HttpTransact.cc b/proxy/http/HttpTransact.cc index 7f440d036e7..0fa29746692 100644 --- a/proxy/http/HttpTransact.cc +++ b/proxy/http/HttpTransact.cc @@ -6753,7 +6753,7 @@ HttpTransact::handle_response_keep_alive_headers(State* s, HTTPVersion ver, HTTP ka_action = KA_DISABLED; } else if (heads->status_get() == HTTP_STATUS_NO_CONTENT && - (s->current.server->transfer_encoding != NO_TRANSFER_ENCODING || s->hdr_info.request_content_length != 0)) { + (s->current.server->transfer_encoding != NO_TRANSFER_ENCODING || heads->get_content_length() != 0)) { // some systems hang until the connection closes when receiving a 204 regardless of the K-A headers // close if there is any body response from the origin ka_action = KA_CLOSE;