examples/httpput: remove use of CURLOPT_PUT

It is deprecated and unnecessary since it already sets CURLOPT_UPLOAD.

Reported-by: Jeroen Ooms
Fixes #6186
Closes #6187
This commit is contained in:
Daniel Stenberg 2020-11-09 01:00:52 +01:00
parent a570f7cd09
commit fa6bbbe167
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2
1 changed files with 1 additions and 4 deletions

View File

@ -89,12 +89,9 @@ int main(int argc, char **argv)
/* we want to use our own read function */
curl_easy_setopt(curl, CURLOPT_READFUNCTION, read_callback);
/* enable uploading */
/* enable uploading (implies PUT over HTTP) */
curl_easy_setopt(curl, CURLOPT_UPLOAD, 1L);
/* HTTP PUT please */
curl_easy_setopt(curl, CURLOPT_PUT, 1L);
/* specify target URL, and note that this URL should include a file
name, not only a directory */
curl_easy_setopt(curl, CURLOPT_URL, url);