Sfoglia il codice sorgente

Cut exit command at 20

Gabriel Gosparo 6 anni fa
parent
commit
5684571568
1 ha cambiato i file con 4 aggiunte e 0 eliminazioni
  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()