summaryrefslogtreecommitdiff
path: root/libcurl/curl_wrap.h
diff options
context:
space:
mode:
authorB. Stack <bgstack15@gmail.com>2022-03-09 14:43:11 +0000
committerB. Stack <bgstack15@gmail.com>2022-03-09 14:43:11 +0000
commit106716ec0daedf3a19bcc0036e81305968c543ee (patch)
tree9e6113f824015cdbf5c954f598d6b58f813a7984 /libcurl/curl_wrap.h
parentMerge branch 'b11.17' into 'master' (diff)
parentadd upstream 11.18 (diff)
downloadFreeFileSync-11.18.tar.gz
FreeFileSync-11.18.tar.bz2
FreeFileSync-11.18.zip
Merge branch 'b11.18' into 'master'11.18
add upstream 11.18 See merge request opensource-tracking/FreeFileSync!42
Diffstat (limited to 'libcurl/curl_wrap.h')
-rw-r--r--libcurl/curl_wrap.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/libcurl/curl_wrap.h b/libcurl/curl_wrap.h
index ba9fbc13..4c41ade4 100644
--- a/libcurl/curl_wrap.h
+++ b/libcurl/curl_wrap.h
@@ -44,7 +44,7 @@ struct CurlOption
class HttpSession
{
public:
- HttpSession(const Zstring& server, bool useTls, const Zstring& caCertFilePath /*optional*/, std::chrono::seconds timeOut); //throw SysError
+ HttpSession(const Zstring& server, bool useTls, const Zstring& caCertFilePath /*optional*/); //throw SysError
~HttpSession();
struct Result
@@ -56,7 +56,8 @@ public:
const std::vector<std::string>& extraHeaders, const std::vector<CurlOption>& extraOptions,
const std::function<void (std::span<const char> buf)>& writeResponse /*throw X*/, //
const std::function<size_t(std::span< char> buf)>& readRequest /*throw X*/, //optional
- const std::function<void (const std::string_view& header)>& receiveHeader /*throw X*/); //throw SysError, X
+ const std::function<void (const std::string_view& header)>& receiveHeader /*throw X*/,
+ int timeoutSec); //throw SysError, X
std::chrono::steady_clock::time_point getLastUseTime() const { return lastSuccessfulUseTime_; }
@@ -66,7 +67,6 @@ private:
const std::string serverPrefix_;
const std::string caCertFilePath_; //optional
- const std::chrono::seconds timeOutSec_;
CURL* easyHandle_ = nullptr;
std::chrono::steady_clock::time_point lastSuccessfulUseTime_ = std::chrono::steady_clock::now();
};
bgstack15