Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 29 Oct 2000 12:07:35 +0900
From:      JINMEI Tatuya / =?ISO-2022-JP?B?GyRCP0BMQEMjOkgbKEI=?= <jinmei@isl.rdc.toshiba.co.jp>
To:        "Jacques A. Vidrine" <n@nectar.com>
Cc:        freebsd-net@FreeBSD.ORG
Subject:   Re: getaddrinfo and the UNIX domain
Message-ID:  <y7vvgucpcp4.wl@condor.isl.rdc.toshiba.co.jp>
In-Reply-To: In your message of "Sat, 28 Oct 2000 16:39:10 -0500" <20001028163909.A77420@hamlet.nectar.com>
References:  <20001028163909.A77420@hamlet.nectar.com>

next in thread | previous in thread | raw e-mail | index | archive | help
>>>>> On Sat, 28 Oct 2000 16:39:10 -0500, 
>>>>> "Jacques A. Vidrine" <n@nectar.com> said:

> Calling getaddrinfo like the following:

>         memset(&hints, 0, sizeof(hints));
>         hints.ai_flags    = AI_PASSIVE;
>         hints.ai_family   = PF_UNSPEC;
>         hints.ai_socktype = SOCK_STREAM;

>         getaddrinfo(NULL, "/tmp/some-socket", &hints, &res);

> will result in `servname not supported for ai_socktype'.

> How should this work?

> OpenLDAP 2.x uses getaddrinfo in this fashion.

> I note that calling getaddrinfo with ai_family = PF_UNIX also fails.

As far as I know, current implementation of getaddrinfo() supports
PF_INET and PF_INET6 only. I'm not 100% sure about the situation of
the latest FreeBSD implemenation, but this is the case at least for
the latest one of KAME's implementation (on which FreeBSD one is
based).

By the way, in my understanding, if getaddrinfo supported PF_UNIX, it
would take the filename as its 1st argument:

         getaddrinfo("/tmp/some-socket", NULL, &hints, &res);

					JINMEI, Tatuya
					Communication Platform Lab.
					Corporate R&D Center, Toshiba Corp.
					jinmei@isl.rdc.toshiba.co.jp


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-net" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?y7vvgucpcp4.wl>