cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: How to close a connection to a server,

From: Jeff Pohlmeyer <yetanothergeek_at_gmail.com>
Date: Thu, 21 Oct 2010 13:42:31 -0500

On Thu, Oct 21, 2010 at 1:28 PM, Shivanand wrote:

> I am facing a problem where in when ever I change the URL and try to
> download a file from the server, previous connection does not get closed.
> Hence the number of server side connections keep increasing when I keep
> changing my tracks at client side,
> I want to open a new connection each time.

It sounds like CURLOPT_FRESH_CONNECT is what you want,
but also have a look at these:
  CURLOPT_MAXCONNECTS
  CURLOPT_FORBID_REUSE

 - Jeff
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2010-10-21