This repository has been archived on 2025-03-02. You can view files and clone it, but cannot push or open issues or pull requests.
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()