cURL / Mailing Lists / curl-library / Single Mail

curl-library

Feature Request - Max Download File size

From: Gautam Mani <Gautam.Mani_at_Mobileum.com>
Date: Mon, 10 Jun 2002 06:09:08 -0700

Hi,

Would it be possible to have an option to specify the max file size which is
permissible to be downloaded through libcurl. Basically we would have one
more option e.g, CURLOPT_MAXFILESIZE which would accept the max size
permissible and one more return code CURLE_FILESIZE_EXCEEDED to indicate
that curl will not honour the request since the file size is more than the
permissible limit.

I have made some changes in the FTP module and fixed this by adding one more
data member to the UserDefined structure, handling of the option in
Curl_setopt and the actual size check in ftp.c after the ftp_getsize call in
ftp_perform. Since I was mainly interested in the FTP protocol and I am not
clear about the other protocol implementations, I have not tried anything in
those. Would it be possible for this feature to be implemented in the main
tree as I think that it could be quite useful and gives more flexibility to
the client of the library? Not to mention of course, that it removes the
headache I would have in upgrading libcurl to future versions :).

Thanks & Cheers,
Gautam

_______________________________________________________________

Don't miss the 2002 Sprint PCS Application Developer's Conference
August 25-28 in Las Vegas - http://devcon.sprintpcs.com/adp/index.cfm?source=osdntextlink
Received on 2002-06-10