summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2021-01-17 18:20:06 +0100
committerDaniel Stenberg <daniel@haxx.se>2021-01-19 11:40:15 +0100
commitea6ce0afade4d74d32512fd17c9940e3a1322bea (patch)
treec6cff7f277c6af2a6c51ee7dd6da0746e5c41060
parentf451206266be6ee6c843fb3a1b3d1d676a6d56b8 (diff)
downloadcurl-ea6ce0afade4d74d32512fd17c9940e3a1322bea.tar.gz
http: make providing Proxy-Connection header not cause duplicated headers
Fixes test 1180 Bug: https://curl.se/mail/lib-2021-01/0095.html Reported-by: Fabian Keil Closes #6472
-rw-r--r--lib/http.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/http.c b/lib/http.c
index 993dc61af..520ac1070 100644
--- a/lib/http.c
+++ b/lib/http.c
@@ -3123,6 +3123,7 @@ CURLcode Curl_http(struct Curl_easy *data, bool *done)
#ifndef CURL_DISABLE_PROXY
(conn->bits.httpproxy &&
!conn->bits.tunnel_proxy &&
+ !Curl_checkheaders(data, "Proxy-Connection") &&
!Curl_checkProxyheaders(data, conn, "Proxy-Connection"))?
"Proxy-Connection: Keep-Alive\r\n":"",
#else