cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: SO_REUSEADDR

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Fri, 28 Jul 2006 23:56:31 +0200 (CEST)

On Fri, 28 Jul 2006, Sonia Subramanian wrote:

> On WinCE machines when libcurl is used and if the return port is set,

You mean with CURLOPT_LOCALPORT?

> multiple successful attempts occur only at intervals of about 3 minutes.
> That is probably because Windows does not release ports immediately and we
> cannot rebind unless we use SO_REUSEADDR. Would you please let me know if
> there is an option to do this or the code for this will have to be added?

First, this problem is not unique for Windows (CE) but exists for all platform
and is one of the reasons I added CURLOPT_LOCALPORTRANGE.

Then: no there's currently no way to make SO_REUSEADDR get set. I would like
to add a generic socket option callback, but the only patch I got for that was
never corrected and the submitter naver got back and I've not had much time
nor interest enough to write the code myself.

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2006-07-28