On Tue, Dec 08, 2009 at 02:44:27PM +0100, Jonathan Schleifer wrote:

> Just wondering: Why is getaddrinfo breaking POSIX by not being
> thread-safe and what is the thread-safe alternative to it? (Please
> don't tell me to use locks, as that would kill the possibility to
> lookup multiple hosts at once).
> 
> I consider it very strange that an OS still has a thread-unsafe
> getaddrinfo in the year 2009, even though POSIX and RFC 2553 both
> require it to be thread-safe. And it makes it especially hard to
> write portable applications, as there is no way to check if
> getaddrinfo is thread-safe in a configure script.

Nobody did the work yet. If it's very important to you, consider
spending effort making it thread safe. I believe netbsd and freebsd
have thread safe implementations. But actullay verifying that is
pretty hard.

        -Otto

Reply via email to