This repository has been archived on 2025-03-02. You can view files and clone it, but you cannot make any changes to it's state, such as pushing and creating new issues, pull requests or comments.
curunir/curunir.py
Matthias Schiffer 37df134314 Initial commit
2010-05-02 14:55:53 +02:00

21 lines
392 B
Python

from connection.xmpp import XMPPConnection
import signal, sys
run = True
def exithandler(signum, frame):
global run
run = False
signal.signal(signal.SIGINT, exithandler)
signal.signal(signal.SIGTERM, exithandler)
signal.signal(signal.SIGQUIT, exithandler)
connection = XMPPConnection()
connection.connect()
while run:
connection.stream.loop_iter(1)
connection.disconnect()