cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: A question regarding DNS resolution when host part is an IP address

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Mon, 26 Aug 2013 22:23:09 +0200 (CEST)

On Mon, 26 Aug 2013, Mehmet Bozkurt wrote:

> I'm using libcurl version 7.21.1 built for WIN32 (a bit dated I know) with
> IPv6 support enabled.
>
> Reading the docs I got the impression that DNS lookups weren't performed
> when using IP:s instead of host names in connection URL:s.
>
> I've noticed that when using libcurl to connect to an FTP server there is a
> call to getaddrinfo although the URL is ftp://192.168.34.132.
>
> Did I miss a setting to control this feature or did I misunderstand the
> docs?

It shouldn't have to do any calls to getaddrinfo() in that case.

However, I would say that there's a good chance we fixed that among the 600+
bug fixes we've done since that version... If you can repeat it with a modern
libcurl version I'll be interested!

-- 
  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2013-08-26