예제 #1
0
파일: main.py 프로젝트: vabic/l33tnet
def main():

	port = common.PORT
	username = input("Choose a username : "******"", flush=True)

	signal.signal(41, pause_handler)
	signal.signal(42, chat_handler)

	signal.pause()

	chat.chat(port, username)

	p.terminate()
예제 #2
0
파일: main.py 프로젝트: PhiBabin/l33tnet
def main():

	port = common.PORT
	username = input("Choose a username : "******"", flush=True)

	signal.signal(41, pause_handler)
	signal.signal(42, chat_handler)

	signal.pause()

	try:
		chat.chat(port, username)
	except (KeyboardInterrupt, SystemExit): # Handle the ctrl+c
		chat.broadcast(port, chat.encode(username, '{} leaved the chat'.format(username), special=True))
		print('*** Quitting ***')

	p.terminate()
예제 #3
0
파일: main.py 프로젝트: l3robot/l33tnet
def main():

	port = common.PORT
	username = input("Choose a username : "******"", flush=True)

	signal.signal(41, pause_handler)
	signal.signal(42, chat_handler)

	signal.pause()

	try:
		chat.chat(port, username)
	except (KeyboardInterrupt, SystemExit): # Handle the ctrl+c
		chat.broadcast(port, chat.encode(username, '{} leaved the chat'.format(username), special=True))
		print('*** Quitting ***')

	p.terminate()