Handle sending stanzas in chunks if the socket has poor performance.
This commit is contained in:
@@ -138,7 +138,7 @@ class TestLiveSocket(object):
|
||||
"""
|
||||
with self.send_queue_lock:
|
||||
self.send_queue.put(data)
|
||||
self.socket.send(data)
|
||||
return self.socket.send(data)
|
||||
|
||||
# ------------------------------------------------------------------
|
||||
# File Socket
|
||||
|
@@ -121,6 +121,7 @@ class TestSocket(object):
|
||||
if self.disconnected:
|
||||
raise socket.error
|
||||
self.send_queue.put(data)
|
||||
return len(data)
|
||||
|
||||
# ------------------------------------------------------------------
|
||||
# File Socket
|
||||
|
Reference in New Issue
Block a user