cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: Facing an issue while doing FTP download for large file size:

From: lakshmi <lakshmi_at_dikshatech.com>
Date: Thu, 17 Mar 2011 19:11:59 +0530

Even if i try to download a file with 56KB, it leads to an error saying
"23 Failed writing received data to disk/application" !

File also gets downloaded but with 0 size !

Please help out.. this is happening only for download of ftp and sftp !

lakshmi wrote:
> Hi,
>
> Thanks for the reply !
>
> Actually i have even tried passing the exact file size to curl API but
> din't work !
>
>
> Alex Bligh wrote:
>>
>>
>> --On 17 March 2011 18:10:53 +0530 lakshmi <lakshmi_at_dikshatech.com>
>> wrote:
>>
>>> I am trying to do FTP download using the curl API
>>> "CURLOPT_MAXFILESIZE"
>>> for a file which is of 400MB !
>>
>> The curl library list is here:
>> http://cool.haxx.se/mailman/listinfo/curl-library
>>
>>> Curl API is:
>>> curl_easy_setopt(curlHandle_m, CURLOPT_MAXFILESIZE, 3L);
>>>
>>> The following error occurs and the file doesn't get downloaded: "63
>>> Maximum file size exceeded"
>>
>>
>>> From the man page:
>>
>>> CURLOPT_MAXFILESIZE
>>>
>>> Pass a long as parameter. This allows you to specify the maximum
>>> size (in
>>> bytes) of a file to download. If the file requested is larger than this
>>> value, the transfer will not start and CURLE_FILESIZE_EXCEEDED will be
>>> returned.
>>>
>>> The file size is not always known prior to download, and for such files
>>> this option has no effect even if the file transfer ends up being
>>> larger
>>> than this given limit. This concerns both FTP and HTTP transfers.
>>
>> You are setting the maximum file size to 3 bytes. Is that really what
>> you intended? 400MB > 3 bytes.
>>
>
> -------------------------------------------------------------------
> List admin: http://cool.haxx.se/list/listinfo/curl-users
> FAQ: http://curl.haxx.se/docs/faq.html
> Etiquette: http://curl.haxx.se/mail/etiquette.html
>
>

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-03-17