cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: How do I stop a FTP download?

From: Wei Weng <wweng_at_kencast.com>
Date: Mon, 27 Oct 2003 16:39:31 -0500 (EST)

On Sat, 25 Oct 2003, Daniel Stenberg wrote:

> On Fri, 24 Oct 2003, Wei Weng wrote:
>
> > Place something like a global variable inside a write function, (use
> > download as an example) check this variable periodically inside the write
> > function to see if it has been changed to a different value that represents
> > stop. If yes, then return from the write callbackk function. Is that right?
>
> That's one way to do it, sure.
>
Does the write callback function need to return the number of bytes
written to the disk? What is the return value of curl_easy_perform if I
abort the download process using global variable switch I described in
previous email?

Thanks

Wei

-------------------------------------------------------
This SF.Net email sponsored by: ApacheCon 2003,
16-19 November in Las Vegas. Learn firsthand the latest
developments in Apache, PHP, Perl, XML, Java, MySQL,
WebDAV, and more! http://www.apachecon.com/
Received on 2003-11-08