From owner-freebsd-net Mon Jul 16 11:27:33 2001 Delivered-To: freebsd-net@freebsd.org Received: from srv1.cosmo-project.de (srv1.cosmo-project.de [213.83.6.106]) by hub.freebsd.org (Postfix) with ESMTP id CCB5C37B401 for ; Mon, 16 Jul 2001 11:27:24 -0700 (PDT) (envelope-from ticso@mail.cicely.de) Received: from mail.cicely.de (cicely20 [10.1.1.22]) by srv1.cosmo-project.de (8.11.0/8.11.0) with ESMTP id f6GIQwV95221; Mon, 16 Jul 2001 20:26:58 +0200 (CEST) Received: (from ticso@localhost) by mail.cicely.de (8.11.0/8.11.0) id f6GIRkM01339; Mon, 16 Jul 2001 20:27:46 +0200 (CEST) Date: Mon, 16 Jul 2001 20:27:46 +0200 From: Bernd Walter To: Ian Dowse Cc: itojun@iijlab.net, freebsd-net@FreeBSD.ORG, Bernd Walter , Hajimu UMEMOTO Subject: Re: how to get AF_LOCAL from getaddrinfo() Message-ID: <20010716202745.A1326@cicely20.cicely.de> References: <14832.995299015@itojun.org> <200107161844.aa52089@salmon.maths.tcd.ie> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <200107161844.aa52089@salmon.maths.tcd.ie>; from iedowse@maths.tcd.ie on Mon, Jul 16, 2001 at 06:44:39PM +0100 Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Mon, Jul 16, 2001 at 06:44:39PM +0100, Ian Dowse wrote: > In message <14832.995299015@itojun.org>, itojun@iijlab.net writes: > Another important reason to add this feature is for compatibility > with other platforms' getaddrinfo() implementations. I just tried > a random Linux box here, and it seems to have very similar behaviour > to that implemented by my patch. There is also the general idea > that the way to encourage people to use a "preferred" interface is > to make it useful in as many situations as possible :-) The libbind shipped with bind does so. The getaddrinfo described by W. Richard Stevens in Unix Networkprogramming Vol1 describes it for Unix domain sockets In the later case its also for AF_UNSPEC if the host begins with '/' But on the other side I never saw getnameinfo with support for it. Solaris and NetBSD doesn't support it - so your Linux example seems to be very alone (maybe they are using plain bind implementation). I primarily asked for it because I found it in contrib/bind and asumed it to be implemented. Applications usualy have to deal with it thereself anyway especialy if they need to be portable and filling a sockaddr_un is by far the easiest kind of socket tasks to do. getaddrinfo is realy usefull if you have a FQDN or IPv4/6 ASCII address which which are difficult to differenciate and which may have multiple A and AAAA records to try. So I don't know if it's even usefull to have unix domain sockets in getaddrinfo. -- B.Walter COSMO-Project http://www.cosmo-project.de ticso@cicely.de Usergroup info@cosmo-project.de To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message