Added TCP keepalive to telnet and webclient, to make sure to (eventually) catch dead connections. Should help #498, but should test on demo before closing.

This commit is contained in:
Griatch 2014-10-20 23:40:01 +02:00
parent b8dfce9cef
commit 263092b4c9
3 changed files with 5 additions and 1 deletions

View file

@ -50,6 +50,8 @@ class TelnetProtocol(Telnet, StatefulTelnetProtocol, Session):
self.msdp = msdp.Msdp(self)
# mxp support
self.mxp = Mxp(self)
# keepalive watches for dead links
self.transport.setTcpKeepAlive(1)
# add this new connection to sessionhandler so
# the Server becomes aware of it.
self.sessionhandler.connect(self)