From 8afd00f00daf95185e7bd18323f7f838cebf7acb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E7=A5=A5=E8=B6=85?= Date: Wed, 24 Aug 2022 16:43:32 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4HTTP/2=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E5=85=B3=E9=97=ADBody=E7=9A=84=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- internal/nodes/http_request_reverse_proxy.go | 6 ------ 1 file changed, 6 deletions(-) diff --git a/internal/nodes/http_request_reverse_proxy.go b/internal/nodes/http_request_reverse_proxy.go index 678c67f..e321ba1 100644 --- a/internal/nodes/http_request_reverse_proxy.go +++ b/internal/nodes/http_request_reverse_proxy.go @@ -252,12 +252,6 @@ func (this *HTTPRequest) doOriginRequest(failedOriginIds []int64, failedLnNodeId return } - // 在HTTP/2下需要防止因为requestBody而导致Content-Length为空的问题 - if this.RawReq.ProtoMajor == 2 && this.RawReq.ContentLength == 0 && this.RawReq.Body != nil { - _ = this.RawReq.Body.Close() - this.RawReq.Body = nil - } - // 开始请求 resp, err := client.Do(this.RawReq) if err != nil {