SHARE
TWEET

Untitled

a guest Oct 23rd, 2019 74 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  @staticmethod    
  2.     def keepalive():
  3.         while Sender.live:
  4.             time.sleep(5)
  5.             Sender.set_header(4,0,1,1)
  6.             Sender.mySocket.send(Sender.myHeader)
  7.            
  8.  
  9.  
  10.     @staticmethod    
  11.     def send_message():
  12.         t1 = threading.Thread(target = Sender.keepalive)
  13.         while True:
  14.             Sender.live = True
  15.             t1.start
  16.             command = input("CHOOSE MESSAGE TYPE (TEXT/FILE/QUIT)\n")
  17.             Sender.live = False
  18.             if command == "QUIT":
  19.                 Sender.sender_close()
  20.                 t1.join
  21.                 break
  22.             elif command == "TEXT":
  23.                 Sender.send_text()
  24.             elif command == "FILE":
  25.                 Sender.send_file()
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top