cURL / Mailing Lists / curl-library / Single Mail


Re: Libcurl+c-ares when using the multi interface

From: Daniel Stenberg <>
Date: Wed, 11 Jun 2008 22:40:04 +0200 (CEST)

On Tue, 10 Jun 2008, Christopher Palow wrote:

> How about this for a fix? Wešve got to call singlesocket() before
> Curl_async_resolved is called because Curl_async_resolved calls
> SetupConnection() which is likely to get the same file descriptor for the
> new connection (as happens in all the straces Išve looked at for this
> issue).

This explanation puzzles me. If the DNS resolve is compeleted, the socket is
closed and another socket is created (which then is the same file descriptor),
why would libcurl need to tell the app about this? The only reason I see it
would need to tell it anything about this, is if the new socket needs to wait
for something else (read, write) than the previous socket was waiting for.

Or are you saying that the current code doesn't manage to do the above

Received on 2008-06-11