changeset 26968:fd7dc5cc0310

Allow incoming stanzas to match 'our account' if they come from our resource. This makes little sense but is allowed by rfc3921 7.2 for roster pushes and is what ejabberd 2.0.5 uses.
author Paul Aurich <paul@darkrain42.org>
date Fri, 29 May 2009 20:56:46 +0000
parents 9c283917ecf7
children f303787f144d cd78ea46e9bd
files libpurple/protocols/jabber/jutil.c
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/protocols/jabber/jutil.c	Fri May 29 05:11:14 2009 +0000
+++ b/libpurple/protocols/jabber/jutil.c	Fri May 29 20:56:46 2009 +0000
@@ -260,9 +260,10 @@
 	if (!jid)
 		return FALSE;
 
-	equal = (g_str_equal(jid->node, js->user->node) &&
+	equal = (purple_strequal(jid->node, js->user->node) &&
 	         g_str_equal(jid->domain, js->user->domain) &&
-	         jid->resource == NULL);
+	         (jid->resource == NULL ||
+	             g_str_equal(jid->resource, js->user->resource)));
 	jabber_id_free(jid);
 	return equal;
 }