Explorar el Código

Cut exit command at 20

Gabriel Gosparo hace 6 años
padre
commit
5684571568
Se han modificado 1 ficheros con 4 adiciones y 0 borrados
  1. 4 0
      ObjectSsh.py

+ 4 - 0
ObjectSsh.py

@@ -48,8 +48,12 @@ class ObjectSsh(ObjectConnection):
             self.connection_data()
         else:
             self.connection_old()
+        nc = 0
         while self.QUIT:
+            if nc == 20:
+                self.QUIT = False
             # send quit to terminal until exit confirmation
+            nc += 1
             self.command_quit(self.olt.get_write_exit())
         self.stdin.close()
         self.stdout.close()