From 5635265203712650981c479867cdcece01fa6d61 Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Wed, 16 Mar 2011 06:28:12 +0800 Subject: Avoid infinite loop on version result We need to check if type="get". otherwise we will send our version when we will receive the version of the remote entity, and thus going in an infinite loop. --- sleekxmpp/plugins/xep_0092/version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sleekxmpp/plugins/xep_0092/version.py b/sleekxmpp/plugins/xep_0092/version.py index fb3671e4..46bb27f7 100644 --- a/sleekxmpp/plugins/xep_0092/version.py +++ b/sleekxmpp/plugins/xep_0092/version.py @@ -42,7 +42,7 @@ class xep_0092(base_plugin): self.xmpp.register_handler( Callback('Software Version', - StanzaPath('iq/software_version'), + StanzaPath('iq@=get/software_version'), self._handle_version)) register_stanza_plugin(Iq, Version) -- cgit v1.2.3