commit b7cb8fcf319f3c9ded16bcae9c57d93c7ca8b98c
Author: Ondrej Lichtner <olichtne(a)redhat.com>
Date: Fri Mar 29 13:55:00 2013 +0100
NetTestSlave: bug fix for the ServerHandler
There was a bug in the ServerHandler class, with passing parameters in
the remove_connection method. This patch fixes it.
Signed-off-by: Ondrej Lichtner <olichtne(a)redhat.com>
lnst/Slave/NetTestSlave.py | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/lnst/Slave/NetTestSlave.py b/lnst/Slave/NetTestSlave.py
index 5a00b0d..253a75a 100644
--- a/lnst/Slave/NetTestSlave.py
+++ b/lnst/Slave/NetTestSlave.py
@@ -304,14 +304,16 @@ class ServerHandler(object):
def add_connection(self, id, connection):
self._connection_handler.add_connection(id, connection)
- def remove_connection(self, id):
- self._connection_handler.remove_connection(id, connection)
+ def remove_connection(self, key):
+ connection = self._connection_handler.get_connection(key)
+ self._connection_handler.remove_connection(connection)
def clear_connections(self):
self._connection_handler.clear_connections()
def update_connections(self, connections):
for key, connection in connections.iteritems():
+ self.remove_connection(key)
self.add_connection(key, connection)
class NetTestSlave:
Show replies by date