curl-users
bug with curl --continue-at - -O http://foo.com/bar
Date: Sat, 2 Aug 2008 10:08:37 -0400
If curl is asked to continue from where it left off, and the file was
already correctly downloaded, it exits with a result code of 18. This
would be OK I guess if the 18 were used only for this situation, but
apparently it is used for other situations.
I suggest that curl should exit with status 0 if the file is already
downloaded correctly.
I presume that curl doesn't just look for the count of bytes in the
file it's resuming but instead actually verifies that those bytes are
correct.
Below is a shell transcript. My prompt uses two numbers:
* result of previous command
* history number
Dave
0 413 Z% curl --continue-at - -O
http://bits.netbeans.org/dev/nightly/latest/zip/moduleclusters/netbeans-trunk-nightly-200808010201-identity.zip
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 303k 100 303k 0 0 142k 0 0:00:02 0:00:02 --:--:-- 153k
0 414 Z% curl --continue-at - -O
http://bits.netbeans.org/dev/nightly/latest/zip/moduleclusters/netbeans-trunk-nightly-200808010201-identity.zip
** Resuming transfer from byte position 311089
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (18) transfer closed with outstanding read data remaining
18 415 Z%
-------------------------------------------------------------------
List admin: http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2008-08-02