You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by zw...@apache.org on 2022/06/15 22:27:01 UTC
[trafficserver] branch 9.2.x updated: Do not modify Transfer-Encoding header on retry (#8899)
This is an automated email from the ASF dual-hosted git repository.
zwoop pushed a commit to branch 9.2.x
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/9.2.x by this push:
new 41e9fb5dd Do not modify Transfer-Encoding header on retry (#8899)
41e9fb5dd is described below
commit 41e9fb5ddddadd6fe452fe65d381efee8d0e0b59
Author: Masaori Koshiba <ma...@apache.org>
AuthorDate: Tue Jun 14 13:34:53 2022 +0900
Do not modify Transfer-Encoding header on retry (#8899)
(cherry picked from commit f45d490b7c3a3cb91cbc6a815b9939b19101e4d2)
---
proxy/http/HttpSM.cc | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc
index ee65c959d..55a656d4a 100644
--- a/proxy/http/HttpSM.cc
+++ b/proxy/http/HttpSM.cc
@@ -6343,7 +6343,8 @@ HttpSM::attach_server_session()
if (ua_txn->has_request_body(t_state.hdr_info.request_content_length,
t_state.client_info.transfer_encoding == HttpTransact::CHUNKED_ENCODING)) {
// See if we need to insert a chunked header
- if (!t_state.hdr_info.server_request.presence(MIME_PRESENCE_CONTENT_LENGTH)) {
+ if (!t_state.hdr_info.server_request.presence(MIME_PRESENCE_CONTENT_LENGTH) &&
+ !t_state.hdr_info.server_request.presence(MIME_PRESENCE_TRANSFER_ENCODING)) {
// Stuff in a TE setting so we treat this as chunked, sort of.
t_state.server_info.transfer_encoding = HttpTransact::CHUNKED_ENCODING;
t_state.hdr_info.server_request.value_append(MIME_FIELD_TRANSFER_ENCODING, MIME_LEN_TRANSFER_ENCODING, HTTP_VALUE_CHUNKED,