# HG changeset patch # User Mark Doliner # Date 1212396700 0 # Node ID 043e4b0c274e33d96eb89341f845d56298edd857 # Parent 2b997b6905002704e25ca2357994236342637765 Short-circuit earlier if the buddy is offline diff -r 2b997b690500 -r 043e4b0c274e libpurple/protocols/oscar/oscar.c --- a/libpurple/protocols/oscar/oscar.c Mon Jun 02 05:06:58 2008 +0000 +++ b/libpurple/protocols/oscar/oscar.c Mon Jun 02 08:51:40 2008 +0000 @@ -5654,17 +5654,23 @@ return NULL; } -void oscar_tooltip_text(PurpleBuddy *b, PurpleNotifyUserInfo *user_info, gboolean full) { - PurpleConnection *gc = b->account->gc; - OscarData *od = gc->proto_data; - aim_userinfo_t *userinfo = aim_locate_finduserinfo(od, b->name); - - if (PURPLE_BUDDY_IS_ONLINE(b)) { - oscar_user_info_append_status(gc, user_info, b, userinfo); - - if (full) - oscar_user_info_append_extra_info(gc, user_info, b, userinfo); - } +void oscar_tooltip_text(PurpleBuddy *b, PurpleNotifyUserInfo *user_info, gboolean full) +{ + PurpleConnection *gc; + OscarData *od; + aim_userinfo_t *userinfo; + + if (PURPLE_BUDDY_IS_ONLINE(b)) + return; + + gc = b->account->gc; + od = gc->proto_data; + userinfo = aim_locate_finduserinfo(od, b->name); + + oscar_user_info_append_status(gc, user_info, b, userinfo); + + if (full) + oscar_user_info_append_extra_info(gc, user_info, b, userinfo); } char *oscar_status_text(PurpleBuddy *b)