Commit 5572c34e authored by Grégory Wisniewski's avatar Grégory Wisniewski

Handle askPrimary packet as unexpected in ClientElectionHandler.

git-svn-id: https://svn.erp5.org/repos/neo/trunk@1555 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent ca9dd7b4
......@@ -64,6 +64,12 @@ class ElectionHandler(MasterHandler):
class ClientElectionHandler(ElectionHandler):
# FIXME: this packet is not allowed here, but handled in MasterHandler
# a global handler review is required.
def askPrimary(self, conn, packet):
from neo.protocol import UnexpectedPacketError
raise UnexpectedPacketError, "askPrimary on server connection"
def packetReceived(self, conn, packet):
node = self.app.nm.getByAddress(conn.getAddress())
if not node.isBroken():
......
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