mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-05-31 08:41:11 +00:00
[qw] Update http_progress for recent curl
CURLOPT_PROGRESSFUNCTION was deprecated in favor of CURLOPT_XFERINFOFUNCTION (and the parameters for the callback adjusted). I'm not sure why this didn't trigger until now.
This commit is contained in:
parent
6f429311c9
commit
d59dcba37d
1 changed files with 3 additions and 3 deletions
|
@ -47,8 +47,8 @@ static CURL *easy_handle;
|
||||||
static CURLM *multi_handle;
|
static CURLM *multi_handle;
|
||||||
|
|
||||||
static int
|
static int
|
||||||
http_progress (void *clientp, double dltotal, double dlnow,
|
http_progress (void *clientp, curl_off_t dltotal, curl_off_t dlnow,
|
||||||
double ultotal, double uplow)
|
curl_off_t ultotal, curl_off_t uplow)
|
||||||
{
|
{
|
||||||
return 0; //non-zero = abort
|
return 0; //non-zero = abort
|
||||||
}
|
}
|
||||||
|
@ -87,7 +87,7 @@ CL_HTTP_StartDownload (void)
|
||||||
|
|
||||||
curl_easy_setopt (easy_handle, CURLOPT_NOPROGRESS, 1L);
|
curl_easy_setopt (easy_handle, CURLOPT_NOPROGRESS, 1L);
|
||||||
curl_easy_setopt (easy_handle, CURLOPT_NOSIGNAL, 1L);
|
curl_easy_setopt (easy_handle, CURLOPT_NOSIGNAL, 1L);
|
||||||
curl_easy_setopt (easy_handle, CURLOPT_PROGRESSFUNCTION, http_progress);
|
curl_easy_setopt (easy_handle, CURLOPT_XFERINFOFUNCTION, http_progress);
|
||||||
curl_easy_setopt (easy_handle, CURLOPT_WRITEFUNCTION, http_write);
|
curl_easy_setopt (easy_handle, CURLOPT_WRITEFUNCTION, http_write);
|
||||||
|
|
||||||
curl_easy_setopt (easy_handle, CURLOPT_URL, cls.downloadurl->str);
|
curl_easy_setopt (easy_handle, CURLOPT_URL, cls.downloadurl->str);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue