# HG changeset patch # User Nathan Walp # Date 1125514827 0 # Node ID e8890f996cc1a3582dd4adac7a4b1b275268239d # Parent d3755a7ddd8236d95f4ee5eb92dd0323ed15b714 [gaim-migrate @ 13621] patch from Zmitrok committer: Tailor Script diff -r d3755a7ddd82 -r e8890f996cc1 COPYRIGHT --- a/COPYRIGHT Wed Aug 31 18:50:38 2005 +0000 +++ b/COPYRIGHT Wed Aug 31 19:00:27 2005 +0000 @@ -246,4 +246,5 @@ Nickolai Zeldovich Marco Ziech Piotr Zielinski +Zmitrok Jaroen Zwartepoorte diff -r d3755a7ddd82 -r e8890f996cc1 src/protocols/jabber/chat.c --- a/src/protocols/jabber/chat.c Wed Aug 31 18:50:38 2005 +0000 +++ b/src/protocols/jabber/chat.c Wed Aug 31 19:00:27 2005 +0000 @@ -895,16 +895,19 @@ if(!(chat = jabber_chat_find_by_id(js, id))) return; + /* defaults, in case the conference server doesn't + * support this request */ + chat->xhtml = TRUE; + if((error = xmlnode_get_child(packet, "error"))) { - /* defaults, in case the conference server doesn't - * support this request */ - chat->xhtml = TRUE; return; } if(!(query = xmlnode_get_child(packet, "query"))) return; + chat->xhtml = FALSE; + for(x = xmlnode_get_child(query, "feature"); x; x = xmlnode_get_next_twin(x)) { const char *var = xmlnode_get_attrib(x, "var"); @@ -918,10 +921,15 @@ { JabberIq *iq; xmlnode *query; + char *room_jid; + + room_jid = g_strdup_printf("%s@%s", chat->room, chat->server); iq = jabber_iq_new_query(chat->js, JABBER_IQ_GET, "http://jabber.org/protocol/disco#info"); + xmlnode_set_attrib(iq->node, "to", room_jid); + query = xmlnode_get_child(iq->node, "query"); xmlnode_set_attrib(query, "node", "http://jabber.org/protocol/muc#traffic"); @@ -929,6 +937,8 @@ jabber_iq_set_callback(iq, jabber_chat_disco_traffic_cb, GINT_TO_POINTER(chat->id)); jabber_iq_send(iq); + + g_free(room_jid); }