diff options
Diffstat (limited to 'src/net')
-rw-r--r-- | src/net/download.cpp | 6 | ||||
-rw-r--r-- | src/net/download.h | 2 |
2 files changed, 8 insertions, 0 deletions
diff --git a/src/net/download.cpp b/src/net/download.cpp index c3b15cd2b..073990b07 100644 --- a/src/net/download.cpp +++ b/src/net/download.cpp @@ -343,6 +343,7 @@ int Download::downloadThread(void *ptr) addProxy(d->mCurl); secureCurl(d->mCurl); } + addCommonFlags(d->mCurl); if ((res = curl_easy_perform(d->mCurl)) != 0 && (d->mOptions.cancel == 0u) && @@ -608,6 +609,11 @@ void Download::addHeaders(CURL *const curl A_UNUSED) } #endif // LIBCURL_VERSION_NUM >= 0x071507 +void Download::addCommonFlags(CURL *const curl) +{ + curl_easy_setopt(curl, CURLOPT_STDERR, logger->getFile()); +} + void Download::prepareForm(curl_httppost **form, const std::string &fileName) { curl_httppost *lastPtr = nullptr; diff --git a/src/net/download.h b/src/net/download.h index c70118987..5b736d58d 100644 --- a/src/net/download.h +++ b/src/net/download.h @@ -106,6 +106,8 @@ class Download final static void addHeaders(CURL *const curl); + static void addCommonFlags(CURL *const curl); + static unsigned long adlerBuffer(const char *const buffer, int size); static std::string getUploadResponse() |