http: rename CURLOPT_FILE to CURLOPT_WRITEDATA
The CURLOPT_FILE name is an alias for CURLOPT_WRITEDATA, the CURLOPT_WRITEDATA name has been preferred since curl 7.9.7, released in May 2002[1]. 1. https://curl.se/libcurl/c/CURLOPT_WRITEDATA.html Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
5db9d38359
commit
8dda4cbdf2
@ -883,7 +883,7 @@ static struct remote_lock *lock_remote(const char *path, long timeout)
|
||||
slot->results = &results;
|
||||
curl_setup_http(slot->curl, url, DAV_LOCK, &out_buffer, fwrite_buffer);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_HTTPHEADER, dav_headers);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_FILE, &in_buffer);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_WRITEDATA, &in_buffer);
|
||||
|
||||
CALLOC_ARRAY(lock, 1);
|
||||
lock->timeout = -1;
|
||||
@ -1142,7 +1142,7 @@ static void remote_ls(const char *path, int flags,
|
||||
curl_setup_http(slot->curl, url, DAV_PROPFIND,
|
||||
&out_buffer, fwrite_buffer);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_HTTPHEADER, dav_headers);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_FILE, &in_buffer);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_WRITEDATA, &in_buffer);
|
||||
|
||||
if (start_active_slot(slot)) {
|
||||
run_active_slot(slot);
|
||||
@ -1216,7 +1216,7 @@ static int locking_available(void)
|
||||
curl_setup_http(slot->curl, repo->url, DAV_PROPFIND,
|
||||
&out_buffer, fwrite_buffer);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_HTTPHEADER, dav_headers);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_FILE, &in_buffer);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_WRITEDATA, &in_buffer);
|
||||
|
||||
if (start_active_slot(slot)) {
|
||||
run_active_slot(slot);
|
||||
|
Reference in New Issue
Block a user