Commit 526c8ce0 authored by Grégory Wisniewski's avatar Grégory Wisniewski

When a node detect that it is sending a too big message, this is a bug, so raise

instead of notify the peer of the error. 


git-svn-id: https://svn.erp5.org/repos/neo/branches/prototype3@1131 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent b32e01b3
......@@ -369,9 +369,7 @@ class Connection(BaseConnection):
self.write_buf += packet.encode()
except PacketMalformedError, m:
logging.critical('trying to send a too big message')
packet = protocol.internalError(m)
assert len(packet.body) < protocol.MAX_PACKET_SIZE
return self.notify(packet)
raise
# If this is the first time, enable polling for writing.
if self.write_buf:
......
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