From 974733ff462caa17690e74b214bdc78e512f13db Mon Sep 17 00:00:00 2001 From: Jan Date: Fri, 10 Mar 2017 13:33:40 +0100 Subject: [PATCH] also compile with cURL Version less than 7.32.0 --- libgrive/src/http/CurlAgent.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libgrive/src/http/CurlAgent.cc b/libgrive/src/http/CurlAgent.cc index eee9a8d..8a9d43f 100644 --- a/libgrive/src/http/CurlAgent.cc +++ b/libgrive/src/http/CurlAgent.cc @@ -190,8 +190,10 @@ long CurlAgent::ExecCurl( struct curl_slist *slist = SetHeader( m_pimpl->curl, hdr ) ; curl_easy_setopt(curl, CURLOPT_NOPROGRESS, 0L); - curl_easy_setopt(curl, CURLOPT_XFERINFOFUNCTION, progress_callback); - curl_easy_setopt(curl, CURLOPT_XFERINFODATA, this); + #if LIBCURL_VERSION_NUM >= 0x072000 + curl_easy_setopt(curl, CURLOPT_XFERINFOFUNCTION, progress_callback); + curl_easy_setopt(curl, CURLOPT_XFERINFODATA, this); + #endif CURLcode curl_code = ::curl_easy_perform(curl);