[Pidgin] #721: Jabber: Chat join failure message
Pidgin
trac at pidgin.im
Mon May 7 01:44:13 EDT 2007
#721: Jabber: Chat join failure message
--------------------------+-------------------------------------------------
Reporter: sadrul | Owner: nwalp
Type: defect | Status: new
Priority: minor | Milestone: 2.0.1
Component: libpurple | Version: 2.0
Keywords: jabber, chat | Pending: 0
--------------------------+-------------------------------------------------
When I try to join a non-existent chat room (eg.
devel at developer.pidgin.im), I get the following reply:
{{{
<presence from='devel at developer.pidgin.im/sadrul'
to='sadrul at pidgin.im/tmp'
type='error'><show>away</show><status>...</status><c
xmlns='http://jabber.org/
protocol/caps' node='http://pidgin.im/caps' ver='2.0.0'/><x
xmlns='http://jabber.org/protocol/muc'/><error code='404' type='cancel
'><remote-server-not-fou
nd xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/></error></presence>
}}}
Looking at the code, it looks like the error is detected, but because the
resource is not NULL ('sadrul' in this case), the error message is
discarded, and joining chat appears to have succeeded. But when trying to
leave this chat, it keeps on rejoining the chat room. The following patch
seems to get rid of the problem:
{{{
#
# old_revision [00dc566bfedcca2a9b44f91cf7e9a73f8270b63a]
#
# patch "libpurple/protocols/jabber/presence.c"
# from [1c89b12b65ab699cd91ee9987b37e452c4abe119]
# to [61621328d209003e313770bcf74443b2f3eb2e9b]
#
============================================================
--- libpurple/protocols/jabber/presence.c
1c89b12b65ab699cd91ee9987b37e452c4abe119
+++ libpurple/protocols/jabber/presence.c
61621328d209003e313770bcf74443b2f3eb2e9b
@@ -391,7 +391,7 @@ void jabber_presence_parse(JabberStream
static int i = 1;
char *room_jid = g_strdup_printf("%s@%s", jid->node,
jid->domain);
- if(state == JABBER_BUDDY_STATE_ERROR && jid->resource ==
NULL) {
+ if (state == JABBER_BUDDY_STATE_ERROR) {
char *title, *msg = jabber_parse_error(js,
packet);
if(chat->conv) {
}}}
I am not really familiar with the XMPP code/protocol. So I am holding off
from committing the patch.
--
Ticket URL: <http://developer.pidgin.im/ticket/721>
Pidgin <http://pidgin.im>
Pidgin
More information about the Tracker
mailing list