Re: Downloading files from an FTP server
Date: Tue, 7 Apr 2009 23:29:00 +0200 (CEST)
On Tue, 7 Apr 2009, Angus March wrote:
> It seems to me that libcurl wants to know everything it is doing before it
> begins the xfer. Is that true?
It depends on what you consider "everything" to be.
> Am I going to need to make one connection for listing the files and then
> another for downloading them? That would be a waste.
Don't confuse multiple libcurl requests with multiple connections. You'll have
to do the former but not the latter.
> headerlist = curl_slist_append(headerlist, "RETR " + file);
You can't do LIST/RETR/STOR etc in QUOTE commands. In other words: all
commands that open or use the data connection must be done using the URL to
specify the file/dir.
-- / daniel.haxx.seReceived on 2009-04-07