Merge "Remove unneeded setting of SO_REUSEADDR."
This commit is contained in:
commit
177e531a2e
@ -199,7 +199,6 @@ def get_socket(conf):
|
|||||||
raise Exception(_('Could not bind to %s:%s '
|
raise Exception(_('Could not bind to %s:%s '
|
||||||
'after trying for %s seconds') % (
|
'after trying for %s seconds') % (
|
||||||
bind_addr[0], bind_addr[1], bind_timeout))
|
bind_addr[0], bind_addr[1], bind_timeout))
|
||||||
sock.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
|
|
||||||
# in my experience, sockets can hang around forever without keepalive
|
# in my experience, sockets can hang around forever without keepalive
|
||||||
sock.setsockopt(socket.SOL_SOCKET, socket.SO_KEEPALIVE, 1)
|
sock.setsockopt(socket.SOL_SOCKET, socket.SO_KEEPALIVE, 1)
|
||||||
sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_NODELAY, 1)
|
sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_NODELAY, 1)
|
||||||
|
@ -281,7 +281,6 @@ class TestWSGI(unittest.TestCase):
|
|||||||
self.assertTrue(isinstance(sock, MockSocket))
|
self.assertTrue(isinstance(sock, MockSocket))
|
||||||
expected_socket_opts = {
|
expected_socket_opts = {
|
||||||
socket.SOL_SOCKET: {
|
socket.SOL_SOCKET: {
|
||||||
socket.SO_REUSEADDR: 1,
|
|
||||||
socket.SO_KEEPALIVE: 1,
|
socket.SO_KEEPALIVE: 1,
|
||||||
},
|
},
|
||||||
socket.IPPROTO_TCP: {
|
socket.IPPROTO_TCP: {
|
||||||
|
Loading…
Reference in New Issue
Block a user