aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--protocols/jabber/jabber_util.c2
-rw-r--r--tests/check_jabber_util.c6
2 files changed, 4 insertions, 4 deletions
diff --git a/protocols/jabber/jabber_util.c b/protocols/jabber/jabber_util.c
index 6e103609..a0266d3e 100644
--- a/protocols/jabber/jabber_util.c
+++ b/protocols/jabber/jabber_util.c
@@ -457,7 +457,7 @@ struct jabber_buddy *jabber_buddy_by_jid( struct im_connection *ic, char *jid_,
}
if( bud == NULL && ( flags & GET_BUDDY_CREAT ) &&
- ( imcb_find_buddy( ic, jid ) || bare_exists ) )
+ ( bare_exists || imcb_find_buddy( ic, jid ) ) )
{
*s = '/';
bud = jabber_buddy_add( ic, jid );
diff --git a/tests/check_jabber_util.c b/tests/check_jabber_util.c
index 4728c5ee..d105f52a 100644
--- a/tests/check_jabber_util.c
+++ b/tests/check_jabber_util.c
@@ -13,12 +13,12 @@ static void check_buddy_add(int l)
struct jabber_buddy *budw1, *budw2, *budw3, *budn, *bud;
budw1 = jabber_buddy_add( ic, "wilmer@gaast.net/BitlBee" );
- budw1->last_act = time( NULL ) - 100;
+ budw1->last_msg = time( NULL ) - 100;
budw2 = jabber_buddy_add( ic, "WILMER@gaast.net/Telepathy" );
budw2->priority = 2;
- budw2->last_act = time( NULL );
+ budw2->last_msg = time( NULL );
budw3 = jabber_buddy_add( ic, "wilmer@GAAST.NET/bitlbee" );
- budw3->last_act = time( NULL ) - 200;
+ budw3->last_msg = time( NULL ) - 200;
budw3->priority = 4;
/* TODO(wilmer): Shouldn't this just return budw3? */
fail_if( jabber_buddy_add( ic, "wilmer@gaast.net/Telepathy" ) != NULL );