Commit 8b3bc064 authored by Jelte Jansen's avatar Jelte Jansen
Browse files

move reuseaddr directive before bind()


git-svn-id: svn://bind10.isc.org/svn/bind10/branches/parkinglot@437 e5f2f494-b856-4b98-b285-d166d9295462
parent f37a4968
......@@ -96,9 +96,9 @@ class MsgQ:
def setup_listener(self):
"""Set up the listener socket. Internal function."""
self.listen_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
self.listen_socket.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
self.listen_socket.bind(("127.0.0.1", self.c_channel_port))
self.listen_socket.listen(1024)
self.listen_socket.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
self.poller.register(self.listen_socket, select.POLLIN)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment