Subject: Re: gethostbyname & gethostbyaddr in libc thread-safe yet?
To: Jun-ichiro itojun Hagino <itojun@itojun.org>
From: Christos Zoulas <christos@zoulas.com>
List: tech-net
Date: 05/26/2004 08:06:15
On May 26,  1:44pm, itojun@itojun.org (Jun-ichiro itojun Hagino) wrote:
-- Subject: Re: gethostbyname & gethostbyaddr in libc thread-safe yet?

| > The manual page of getaddrinfo is out of date (it is thread-safe in
| > NetBSD-current). I would suggest to look into linking with the lwres_
| > library that comes with bind9. Other than that, you can use mutexes
| > to protect the current gethostbyfoo(), but that will make it really
| > slow. Another approach is to fork, which is worse.
| 
| 	no, getaddrinfo is not thread-safe yet in netbsd-current.
| 
| 	getadddrinfo: _yp_getaddrinfo, see variable __ypcurrent

Yes, only in the yp case. The rest of the cases are.

| 	btw, include/resolve.h was not updated when lib/libc/resolv is updated.
| 	is there any reason why?

I will look into it.

christos