From: Jay Satiro Date: Wed, 17 Jul 2019 05:45:26 +0000 (-0400) Subject: CURLOPT_RANGE.3: Caution against using it for HTTP PUT X-Git-Tag: curl-7_65_2~3 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=28f6fda8dcedbe49dcbdb5c5d3a272486d559abc;p=curl CURLOPT_RANGE.3: Caution against using it for HTTP PUT AFAICT CURLOPT_RANGE does not support ranged HTTP PUT uploads so I've cautioned against using it for that purpose and included a workaround. Bug: https://curl.haxx.se/mail/lib-2019-04/0075.html Reported-by: Christopher Head Closes https://github.com/curl/curl/issues/3814 --- diff --git a/docs/libcurl/opts/CURLOPT_RANGE.3 b/docs/libcurl/opts/CURLOPT_RANGE.3 index e90696c01..02ac2762b 100644 --- a/docs/libcurl/opts/CURLOPT_RANGE.3 +++ b/docs/libcurl/opts/CURLOPT_RANGE.3 @@ -43,6 +43,14 @@ For RTSP, the formatting of a range should follow RFC2326 Section 12.29. For RTSP, byte ranges are \fBnot\fP permitted. Instead, ranges should be given in npt, utc, or smpte formats. +For HTTP PUT uploads this option should not be used, since it may conflict with +other options. If you need to upload arbitrary parts of a file (like for +Amazon's web services) support is limited. We suggest set resume position using +\fICURLOPT_RESUME_FROM(3)\fP, set end (resume+size) position using +\fICURLOPT_INFILESIZE(3)\fP and seek to the resume position before initiating +the transfer for each part. For more information refer to +https://curl.haxx.se/mail/lib-2019-05/0012.html + Pass a NULL to this option to disable the use of ranges. The application does not have to keep the string around after setting this