cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Reusing connection after failed FTP QUOTE command

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Wed, 9 Apr 2008 00:12:54 +0200 (CEST)

On Tue, 8 Apr 2008, Scott Barrett wrote:

> What are your thoughts on permitting a cURL connection to be reused after a
> failed FTP QUOTE command?

[...]

> I'd like to see the same behavior when the status is CURLE_QUOTE_ERROR in
> order to avoid the need to establish a new connection and reauthenticate,
> etc..

Right, I can certainly see the point in supporting this. I think the real
problem is that users can pass in anything in the quote commands, even
commands that change states in ways libcurl doesn't track and thus cannot get
out of after a failed command.

Perhaps we should consider coming up with a way in which the application can
mark commands as "kill connection when failed" or "connection is still fine
when failed". Something like a prefix that can't be mistaken by an actual
command?

> This is really only a performance issue (avoiding
> reconnection/reauthentication) in my eyes, but if you don't think that this
> would be a really bad idea, I will experiment and report back.

I think it is an idea worth following up!

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2008-04-09