cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Interrupting in-progress download

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Wed, 2 Nov 2005 16:53:57 +0100 (CET)

On Wed, 2 Nov 2005, Daniel Lavalliere wrote:

> Assuming a http file download is in progress, CURLOPT_NOSIGNAL = 0 and
> CURLOPT_TIMEOUT=1200,

> is there any way to request libcurl to stop downloading the file now if you
> know the connection just went dead and will not be back up before the
> timeout occurs.

There are two ways: you can set the low speed speed options to have libcurl
abort slow operations, or you set a progress callback and return an error from
that when you think it is about time to stop the transfer.

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2005-11-02