+2010-11-21 Giuseppe Scrivano <gscrivano@gnu.org>
+
+ * ftp.c (getftp): If `count' is bigger than zero, try to resume the
+ download, not restart it.
+ * http.c (gethttp): Likewise.
+ Suggested by: Evgeny Kapun <abacabadabacaba@gmail.com>.
+
2010-11-19 Giuseppe Scrivano <gscrivano@gnu.org>
* fttp.c (getftp): Accept new argument `count'. When `count' is
# define BIN_TYPE_FILE 1
#endif /* def __VMS [else] */
- if (restval && !(con->cmd & DO_LIST))
+ if ((restval && !(con->cmd & DO_LIST)) || count > 0)
{
#ifdef __VMS
int open_id;
#endif /* def __VMS [else] */
}
else if (opt.noclobber || opt.always_rest || opt.timestamping || opt.dirstruct
- || opt.output_document || count > 0)
+ || opt.output_document)
{
if (opt.unlink && file_exists_p (con->target))
{
mkalldirs (hs->local_file);
if (opt.backups)
rotate_backups (hs->local_file);
- if (hs->restval)
+ if (hs->restval || count > 0)
{
#ifdef __VMS
int open_id;
fp = fopen (hs->local_file, "ab");
#endif /* def __VMS [else] */
}
- else if (ALLOW_CLOBBER || count > 0)
+ else if (ALLOW_CLOBBER)
{
if (opt.unlink && file_exists_p (hs->local_file))
{