socket.gethostbyname() thread-safe?

Aahz Maruch aahz at panix.com
Tue Apr 10 10:52:34 EDT 2001


In article <3AD1ABD0.FB728F28 at stroeder.com>,
Michael =?iso-8859-1?Q?Str=F6der?=  <michael at stroeder.com> wrote:
>
>Is socket.gethostbyname() thread-safe on all platforms? It seems to
>me that I have some problems on a Debian Linux box.

Looking at the code, it's *supposed* to be thread-safe, either using the
reentrant gethostbyname() if the platform supports it or using a lock to
allow only a single thread access.  But it's always possible there's a
bug in the configure system for Debian.
-- 
                      --- Aahz  <*>  (Copyright 2001 by aahz at pobox.com)

Androgynous poly kinky vanilla queer het Pythonista   http://www.rahul.net/aahz/
Hugs and backrubs -- I break Rule 6

Why is this newsgroup different from all other newsgroups?



More information about the Python-list mailing list