Simplification when removing a deletable handler.

This commit is contained in:
Lance Stout 2011-02-13 16:40:04 -05:00
parent 34f6195ca5
commit 8b5511c7ec

View file

@ -845,7 +845,7 @@ class XMLStream(object):
self.event_queue.put(('stanza', handler, stanza_copy))
try:
if handler.check_delete():
self.__handlers.pop(self.__handlers.index(handler))
self.__handlers.remove(handler)
except:
pass # not thread safe
unhandled = False