From cd92e340089d4d768c0c1a02af1dadd7dc19be08 Mon Sep 17 00:00:00 2001 From: Art Cancro Date: Wed, 5 May 2010 16:14:01 +0000 Subject: [PATCH] * XMPP login hooks which output protocol data should only activate if this is actually an XMPP session. Ouch. --- citadel/modules/xmpp/serv_xmpp.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/citadel/modules/xmpp/serv_xmpp.c b/citadel/modules/xmpp/serv_xmpp.c index a4a5f28ec..067faa0a1 100644 --- a/citadel/modules/xmpp/serv_xmpp.c +++ b/citadel/modules/xmpp/serv_xmpp.c @@ -510,7 +510,11 @@ void xmpp_async_loop(void) { */ void xmpp_login_hook(void) { xmpp_queue_event(XMPP_EVT_LOGIN, CC->cs_inet_email); - xmpp_delete_old_buddies_who_no_longer_exist_from_the_client_roster(); + + /* only do the protocol stuff if this is an XMPP session */ + if (CC->h_command_function == xmpp_command_loop) { + xmpp_delete_old_buddies_who_no_longer_exist_from_the_client_roster(); + } } -- 2.30.2