cURL / Mailing Lists / curl-library / Single Mail


RE: CURLOPT_LOCALPORT option broken ?!

From: Senthil Raja Velu <>
Date: Thu, 19 Feb 2009 11:12:46 -0800

Yes, I can look into it but only by next month if that's ok.


-----Original Message-----
[] On Behalf Of Daniel Stenberg
Sent: Thursday, February 19, 2009 12:54 AM
To: libcurl development
Subject: Re: CURLOPT_LOCALPORT option broken ?!

On Wed, 18 Feb 2009, Senthil Raja Velu wrote:

> I have installed the latest CURL (7.19.3) on Solaris 10 system. I
tried to
> use the connect only option to create a socket, but the local binding
> if I use it along with the interface option as below;
> curl_easy_setopt(mp_curl, CURLOPT_LOCALPORT,
> mLocalAddress.sin_port);
> curl_easy_setopt(mp_curl, CURLOPT_LOCALPORTRANGE, 1L);
> curl_easy_setopt(mp_curl, CURLOPT_INTERFACE,
> inet_ntoa(mLocalAddress.sin_addr));
> curl_easy_setopt(mp_curl, CURLOPT_CONNECT_ONLY, 1L);

Ah, yes I can see how that quite possibly is not taken care of properly
it would then need to take both use the interface and the local port
account in a single bind() which I guess it doesn't do currently...

Any chance you can look into this issue?

Received on 2009-02-19