cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: [PATCH] ftp: prevent server from hanging on closed data connection

From: e-mail number.cruncher <number.cruncher_at_ntlworld.com>
Date: Thu, 4 Nov 2010 19:50:01 +0000

2010/11/4 Daniel Stenberg <daniel_at_haxx.se>
>
> If we truly see the above mentioned 1 and 2 cases, then I can't see any other alternative than to mark the connection to get closed since I don't see how we can reliably differentiate between 2 and 3.
>
> And yes, we only use the number from responses - as long as we can - as the text may vary between implementations.
>
> --
>

In order to get something working with Red Hat's anaconda's use of
curl --range and FTP servers, I think there are two options:
a) Don't use ABOR at all; download everything. I note that the curl
manpage suggests that this may be the behaviour anyway with some
HTTP/1.1 servers
b) Send ABOR, then close session immediately and re-connect for other
files. I'm not sure why curl maintains a connection to the server in
such a case; as far as I can tell, the command-line --range option can
only be used once anyway, and wouldn't be appropriate for multiple
transfers.
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2010-11-04