diff src/protocols/jabber/iq.c @ 13792:02c7d18f5cc3

[gaim-migrate @ 16204] jabber get info now fetches and displays idle time and version info this is based largely on the work of Andrew Sayman. He submitted a patch back in 2004, and I hacked it all to hell, changed how some things were done. If it works, credit him. If it breaks, blame me. committer: Tailor Script <tailor@pidgin.im>
author Nathan Walp <nwalp@pidgin.im>
date Tue, 30 May 2006 01:30:18 +0000
parents e1e5462b7d81
children 25e63008d3bb
line wrap: on
line diff
--- a/src/protocols/jabber/iq.c	Mon May 29 23:27:30 2006 +0000
+++ b/src/protocols/jabber/iq.c	Tue May 30 01:30:18 2006 +0000
@@ -239,6 +239,11 @@
 	}
 }
 
+void jabber_iq_remove_callback_by_id(JabberStream *js, const char *id)
+{
+	g_hash_table_remove(js->iq_callbacks, id);
+}
+
 void jabber_iq_parse(JabberStream *js, xmlnode *packet)
 {
 	JabberCallbackData *jcd;
@@ -256,7 +261,7 @@
 	if(type && (!strcmp(type, "result") || !strcmp(type, "error"))) {
 		if(id && *id && (jcd = g_hash_table_lookup(js->iq_callbacks, id))) {
 			jcd->callback(js, packet, jcd->data);
-			g_hash_table_remove(js->iq_callbacks, id);
+			jabber_iq_remove_callback_by_id(js, id);
 			return;
 		}
 	}