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
@ -853,7 +853,7 @@ static int probe_rpc(struct rpc_state *rpc, struct slot_results *results)
|
||||
curl_easy_setopt(slot->curl, CURLOPT_POSTFIELDSIZE, 4);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_HTTPHEADER, headers);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_WRITEFUNCTION, fwrite_buffer);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_FILE, &buf);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_WRITEDATA, &buf);
|
||||
|
||||
err = run_slot(slot, results);
|
||||
|
||||
@ -1016,7 +1016,7 @@ retry:
|
||||
rpc_in_data.slot = slot;
|
||||
rpc_in_data.check_pktline = stateless_connect;
|
||||
memset(&rpc_in_data.pktline_state, 0, sizeof(rpc_in_data.pktline_state));
|
||||
curl_easy_setopt(slot->curl, CURLOPT_FILE, &rpc_in_data);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_WRITEDATA, &rpc_in_data);
|
||||
curl_easy_setopt(slot->curl, CURLOPT_FAILONERROR, 0);
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user