curl-library
Re: Ranged PUTs, Content-Range, and Content-Length
Date: Fri, 3 May 2019 17:38:37 -0400
On 5/3/2019 9:55 AM, Daniel Stenberg via curl-library wrote:
> On Thu, 2 May 2019, Christopher Head via curl-library wrote:
>
>>> CURLOPT_RANGE specifically as far as I know is only supposed to be
>>> used for download, not upload (can anyone confirm?)
>>
>> And yet, looking at the source code, there are explicit conditionals to
>> check for CURLOPT_RANGE and turn it into a Content-Range header in an
>> upload.
>
> As I mentioned in the issue [3814], curl does support ranged PUT
> requests since basically the beginning of time and there are even
> tests that verify this.
>
> 3814 = https://github.com/curl/curl/issues/3814
I think this will be unclear to the reporter since he basically wants to
upload arbitrary parts of a file [1]. curl supports resuming an upload
and sets Content-Range in that case (CURLOPT_RESUME_FROM and
CURLOPT_INFILESIZE) but does not support CURLOPT_RANGE for arbitrary
parts, would you agree?
[1]: https://curl.haxx.se/mail/lib-2019-04/0075.html
-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2019-05-03