mirror of
https://opendev.org/x/pyghmi
synced 2026-01-11 18:52:33 +00:00
Increase buffer size
In large environments doing massive requests, give a better chance for the receive socket to retain data on our behalf. Change-Id: I54ef64f7dba19c167f2377164465ece2bc0210de
This commit is contained in:
@@ -375,6 +375,10 @@ class Session(object):
|
||||
tmpsocket = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
|
||||
else:
|
||||
tmpsocket = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
|
||||
try:
|
||||
tmpsocket.setsockopt(socket.SOL_SOCKET, socket.SO_RCVBUF, 16777216)
|
||||
except Exception:
|
||||
pass
|
||||
if server is None:
|
||||
# Rather than wait until send() to bind, bind now so that we have
|
||||
# a port number allocated no matter what
|
||||
|
||||
Reference in New Issue
Block a user