]> git.ipfire.org Git - thirdparty/tornado.git/commitdiff
Do not set AI_ADDRCONFIG in netutil.bind_sockets
authorPhilipp Hagemeister <phihag@phihag.de>
Tue, 4 Sep 2012 10:34:00 +0000 (12:34 +0200)
committerPhilipp Hagemeister <phihag@phihag.de>
Tue, 4 Sep 2012 10:34:00 +0000 (12:34 +0200)
tornado/netutil.py

index 6c5a0a93793c3ed1bdebe2512c6a3e5c9b1e2135..816ac70a474d18477f81af1c8cff8bb08e7603f6 100644 (file)
@@ -261,12 +261,6 @@ def bind_sockets(port, address=None, family=socket.AF_UNSPEC, backlog=128, flags
         address = None
     if flags is None:
         flags = socket.AI_PASSIVE
-        if hasattr(socket, "AI_ADDRCONFIG"):
-            # AI_ADDRCONFIG ensures that we only try to bind on ipv6
-            # if the system is configured for it, but the flag doesn't
-            # exist on some platforms (specifically WinXP, although
-            # newer versions of windows have it)
-            flags |= socket.AI_ADDRCONFIG
     for res in set(socket.getaddrinfo(address, port, family, socket.SOCK_STREAM,
                                   0, flags)):
         af, socktype, proto, canonname, sockaddr = res