mirror of
https://github.com/transmission/transmission
synced 2024-12-21 23:32:35 +00:00
refactor: set CURLOPT_MAXREDIRS
once (#7233)
This commit is contained in:
parent
f1102f0b4d
commit
6bf62959b4
1 changed files with 1 additions and 2 deletions
|
@ -522,7 +522,7 @@ public:
|
|||
(void)curl_easy_setopt(e, CURLOPT_AUTOREFERER, 1L);
|
||||
(void)curl_easy_setopt(e, CURLOPT_ACCEPT_ENCODING, "");
|
||||
(void)curl_easy_setopt(e, CURLOPT_FOLLOWLOCATION, 1L);
|
||||
(void)curl_easy_setopt(e, CURLOPT_MAXREDIRS, -1L);
|
||||
(void)curl_easy_setopt(e, CURLOPT_MAXREDIRS, MaxRedirects);
|
||||
(void)curl_easy_setopt(e, CURLOPT_NOSIGNAL, 1L);
|
||||
(void)curl_easy_setopt(e, CURLOPT_PRIVATE, &task);
|
||||
(void)curl_easy_setopt(e, CURLOPT_IPRESOLVE, task.ipProtocol());
|
||||
|
@ -576,7 +576,6 @@ public:
|
|||
(void)curl_easy_setopt(e, CURLOPT_VERBOSE, curl_verbose ? 1L : 0L);
|
||||
(void)curl_easy_setopt(e, CURLOPT_WRITEDATA, &task);
|
||||
(void)curl_easy_setopt(e, CURLOPT_WRITEFUNCTION, &tr_web::Impl::onDataReceived);
|
||||
(void)curl_easy_setopt(e, CURLOPT_MAXREDIRS, MaxRedirects);
|
||||
|
||||
if (auto const addrstr = task.bind_address(); addrstr)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue