From 17fa798247bf1a9b18de2c4848039f940d819f31 Mon Sep 17 00:00:00 2001 From: Wilmer van der Gaast Date: Fri, 20 Apr 2007 22:02:05 -0700 Subject: Jabber module should always send the status information of the primary resource now, instead of just whatever came in last. --- protocols/jabber/presence.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'protocols') diff --git a/protocols/jabber/presence.c b/protocols/jabber/presence.c index f577e56a..ef92740a 100644 --- a/protocols/jabber/presence.c +++ b/protocols/jabber/presence.c @@ -71,10 +71,10 @@ xt_status jabber_pkt_presence( struct xt_node *node, gpointer data ) else bud->priority = 0; - /* FIXME: What to send if there are other resources??? */ - imcb_buddy_status( ic, bud->bare_jid, OPT_LOGGED_IN | is_away, - ( is_away && bud->away_state ) ? bud->away_state->full_name : NULL, - bud->away_message ); + if( bud == jabber_buddy_by_jid( ic, bud->bare_jid, 0 ) ) + imcb_buddy_status( ic, bud->bare_jid, OPT_LOGGED_IN | is_away, + ( is_away && bud->away_state ) ? bud->away_state->full_name : NULL, + bud->away_message ); } else if( strcmp( type, "unavailable" ) == 0 ) { -- cgit v1.2.3