curl-users
Re: TODO
Date: Tue, 24 Jun 2003 11:00:26 +0200 (CEST)
On Tue, 24 Jun 2003, vice wrote:
[I'm cc'ing this reply to an off-list mail to the curl-users mailing list]
> When I use ranges and the -o or -O options I usually combined it with the -f
> because I don't want the errors produced by a missing file to have it on
> files, but usually, the web server is configured to send an html page
> explaining that some file is missed so I get a file at the output. I think
> that sometimes this can be avoided if the output can be condicioned to some
> amount of byte. Something similar to: Don't output anithing if the size is
> less than xx KB.
Thanks for your suggestion!
If you use -f and the file is missing, you should be able to check the return
code to detect this situation. In these cases curl shouldn't actually output
any data.
I don't really see how an option like you suggest will make you, unless you
already know before how big your download file is. And if you DO know, you can
easily make a wrapper script yourself that performs this size-check.
-- Daniel Stenberg -- curl: been grokking URLs since 1998 ------------------------------------------------------- This SF.Net email is sponsored by: INetU Attention Web Developers & Consultants: Become An INetU Hosting Partner. Refer Dedicated Servers. We Manage Them. You Get 10% Monthly Commission! INetU Dedicated Managed Hosting http://www.inetu.net/partner/index.phpReceived on 2003-06-24