diff options
Diffstat (limited to 'curl_fix.patch')
-rw-r--r-- | curl_fix.patch | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/curl_fix.patch b/curl_fix.patch new file mode 100644 index 000000000000..4b1ee1b0f955 --- /dev/null +++ b/curl_fix.patch @@ -0,0 +1,29 @@ +diff -r -u a/libcurl/curl_wrap.h b/libcurl/curl_wrap.h +--- a/libcurl/curl_wrap.h 2020-07-22 13:22:19.000000000 +0200 ++++ b/libcurl/curl_wrap.h 2020-12-05 14:38:38.000000000 +0100 +@@ -138,8 +138,9 @@ + ZEN_CHECK_CASE_FOR_CONSTANT(CURLE_HTTP3); + ZEN_CHECK_CASE_FOR_CONSTANT(CURL_LAST); + ZEN_CHECK_CASE_FOR_CONSTANT(CURLE_QUIC_CONNECT_ERROR); ++ ZEN_CHECK_CASE_FOR_CONSTANT(CURLE_PROXY); + } +- static_assert(CURL_LAST == CURLE_QUIC_CONNECT_ERROR + 1); ++ static_assert(CURL_LAST == CURLE_PROXY + 1); + + return replaceCpy<std::wstring>(L"Curl status %x", L"%x", numberTo<std::wstring>(static_cast<int>(sc))); + } +@@ -148,12 +149,10 @@ + void applyCurlOptions(CURL* easyHandle, const std::vector<CurlOption>& options) //throw SysError + { + for (const CurlOption& opt : options) +- { +- const CURLcode rc = ::curl_easy_setopt(easyHandle, opt.option, opt.value); +- if (rc != CURLE_OK) ++ if (const CURLcode rc = ::curl_easy_setopt(easyHandle, opt.option, opt.value); ++ rc != CURLE_OK) + throw SysError(formatSystemError("curl_easy_setopt(" + numberTo<std::string>(static_cast<int>(opt.option)) + ")", + formatCurlStatusCode(rc), utfTo<std::wstring>(::curl_easy_strerror(rc)))); +- } + } + } + } |