From owner-freebsd-hackers Sun Sep 29 22:15:22 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EB2D337B401 for ; Sun, 29 Sep 2002 22:15:21 -0700 (PDT) Received: from piglet.dstc.edu.au (piglet.dstc.edu.au [130.102.176.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id 19D1C43E42 for ; Sun, 29 Sep 2002 22:15:21 -0700 (PDT) (envelope-from freebsd-lists@lister.dnsalias.net) Received: from ilister.dialup.dstc.edu.au (ilister.dialup.dstc.edu.au [130.102.182.103]) by piglet.dstc.edu.au (8.12.3/8.12.3) with ESMTP id g8U5F64s016934; Mon, 30 Sep 2002 15:15:07 +1000 (EST) Received: from localhost (ilister@localhost) by ilister.dialup.dstc.edu.au (8.11.1/8.11.1) with ESMTP id g8U5F4O60401; Mon, 30 Sep 2002 15:15:05 +1000 (EST) (envelope-from freebsd-lists@lister.dnsalias.net) Date: Mon, 30 Sep 2002 15:15:04 +1000 (EST) From: Ian Lister X-X-Sender: ilister@sapporo.home To: Hiten Pandya Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: gethostbyname_r() fbsd equiv? In-Reply-To: <20020927144504.A42463@angelica.unixdaemons.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Spam-Checked: SPAMASSASSIN: This message probably not SPAM X-Spam-Score: -4.5, Required: 5 X-Virus-Scanned: Message: ok X-Scanned-By: MIMEDefang 2.9 (www dot roaringpenguin dot com slash mimedefang) Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 27 Sep 2002, Hiten Pandya wrote: >Doesnt getaddrinfo() do whatever gethostbyname() can do? And also, if >my source of information is correct, getaddrinfo() should be thread-safe >and also, it is under the POSIX p1003.1g. Generally speaking, yes. Actually, POSIX 1003.1g doesn't require thread safety, but RFC 2553 does. Unfortunately FreeBSD doesn't currently have a thread safe implementation, and so gethostbyname is sadly a better choice if you need thread safety. (I think this is the only platform I've come across where this is the case) Ian To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message