Commit dcb4ed9a authored by Vincent Pelletier's avatar Vincent Pelletier

Don't call onConnectionClosed here.

onConnectionClosed is already called inside Connection.close() when peer
is identified (via setOnClose). Calling it here would trigger an exception
as it verifies that _connection is set before un-setting it.
As a replacement, verify that _connection is not set when
Connection.close() returns (so onConnectionClosed was actually called).

git-svn-id: https://svn.erp5.org/repos/neo/trunk@2212 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent 17f8426b
......@@ -48,7 +48,7 @@ class IdentificationHandler(EventHandler):
elif node.isConnected():
# cut previous connection
node.getConnection().close()
node.onConnectionClosed()
assert not node.isConnected()
node.setRunning()
elif node_type == NodeTypes.STORAGE:
from neo.storage.handlers.storage import StorageOperationHandler
......
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