Skip to content

Commit 1c2dbf2

Browse files
tgcgitster
authored andcommitted
http: support curl < 7.10.7
Commit dd61399 introduced support for http proxies that require authentication but it relies on the CURL_PROXYAUTH option which was added in curl 7.10.7. This makes sure proxy authentication is only enabled if libcurl can support it. Signed-off-by: Tom G. Christensen <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent dd61399 commit 1c2dbf2

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

http.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,9 @@ static CURL *get_curl_handle(void)
297297

298298
if (curl_http_proxy) {
299299
curl_easy_setopt(result, CURLOPT_PROXY, curl_http_proxy);
300+
#if LIBCURL_VERSION_NUM >= 0x070a07
300301
curl_easy_setopt(result, CURLOPT_PROXYAUTH, CURLAUTH_ANY);
302+
#endif
301303
}
302304

303305
return result;

0 commit comments

Comments
 (0)