A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2003-July/037034.html below:

[Python-Dev] New branch for r23c2 work

[Python-Dev] New branch for r23c2 workMartin v. Löwis martin@v.loewis.de
22 Jul 2003 08:12:56 +0200
Skip Montanaro <skip@pobox.com> writes:

> I've been thusfar unable to get the code in getaddrinfo.c to compile as part
> of socketmodule.c (errors about missing #defines and struct members).

And you shouldn't: OSX has its own implementation of getaddrinfo, so
you don't need the emulation code from getaddrinfo.c.

> Maybe the solution for the common case is easier.  In the common case of:
> 
>     s = socket.socket (socket.AF_INET, socket.SOCK_STREAM) 
>     s.bind (('',0))
> 
> when you get into setipaddr() name[0] will always be '\0' and so you'll take
> the first branch.  Do you need all of getaddrinfo()'s bells and whistles to
> properly set up addr_ret in this case?  At worst, can't the getaddrinfo()
> call be made once and then cached?

OTOH, we shouldn't work around performance problems on certain
systems. Instead, we should report them to the system vendors and wait
for fixes from them.

It's worse enough that we need to work around functional problems
(getaddrinfo not being thread-safe even though the spec says it should be).

Regards,
Martin




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4