diff options
author | MaZderMind <git@mazdermind.de> | 2015-09-02 15:17:54 +0200 |
---|---|---|
committer | MaZderMind <git@mazdermind.de> | 2015-09-02 15:17:54 +0200 |
commit | 13ef8b7d796025f412874349929296e01dab2672 (patch) | |
tree | 282cb83fcb82c3d6dcb884c126398e9b4e2bd102 /voctocore/lib/tcpmulticonnection.py | |
parent | c61fe2b667079168387376da1c09823967476b21 (diff) |
fix command server when dealing with very short lived connections, like
Diffstat (limited to 'voctocore/lib/tcpmulticonnection.py')
-rw-r--r-- | voctocore/lib/tcpmulticonnection.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/voctocore/lib/tcpmulticonnection.py b/voctocore/lib/tcpmulticonnection.py index e6f8b5b..e9caf2c 100644 --- a/voctocore/lib/tcpmulticonnection.py +++ b/voctocore/lib/tcpmulticonnection.py @@ -37,5 +37,6 @@ class TCPMultiConnection(object): return True def close_connection(self, conn): - del(self.currentConnections[conn]) + if conn in self.currentConnections: + del(self.currentConnections[conn]) self.log.info('Now %u Receiver connected', len(self.currentConnections)) |