libpurple/protocols/qq/buddy_info.c

branch
release-2.4.3
changeset 23213
7aaa8e8233bc
parent 23212
a39a33c79a3f
equal deleted inserted replaced
23212:a39a33c79a3f 23213:7aaa8e8233bc
206 } 206 }
207 207
208 return FALSE; 208 return FALSE;
209 } 209 }
210 210
211 static PurpleNotifyUserInfo * 211 static PurpleNotifyUserInfo *
212 info_to_notify_user_info(const contact_info *info) 212 info_to_notify_user_info(const contact_info *info)
213 { 213 {
214 PurpleNotifyUserInfo *user_info = purple_notify_user_info_new(); 214 PurpleNotifyUserInfo *user_info = purple_notify_user_info_new();
215 const gchar *intro; 215 const gchar *intro;
216 gboolean has_extra_info = FALSE; 216 gboolean has_extra_info = FALSE;
217 217
824 static void qq_refresh_buddy_and_myself(contact_info *info, PurpleConnection *gc) 824 static void qq_refresh_buddy_and_myself(contact_info *info, PurpleConnection *gc)
825 { 825 {
826 PurpleBuddy *b; 826 PurpleBuddy *b;
827 qq_data *qd; 827 qq_data *qd;
828 qq_buddy *q_bud; 828 qq_buddy *q_bud;
829 gchar *alias_utf8; 829 gchar *alias_utf8, *purple_name;
830 gchar *purple_name;
831 PurpleAccount *account = purple_connection_get_account(gc); 830 PurpleAccount *account = purple_connection_get_account(gc);
832 831
833 qd = (qq_data *) gc->proto_data; 832 qd = (qq_data *) gc->proto_data;
834 purple_name = uid_to_purple_name(strtol(info->uid, NULL, 10)); 833 purple_name = uid_to_purple_name(strtol(info->uid, NULL, 10));
835 834
1008 bytes += qq_get32(&uid, decr_buf + bytes); 1007 bytes += qq_get32(&uid, decr_buf + bytes);
1009 bytes += qq_get32(&onlineTime, decr_buf + bytes); 1008 bytes += qq_get32(&onlineTime, decr_buf + bytes);
1010 bytes += qq_get16(&level, decr_buf + bytes); 1009 bytes += qq_get16(&level, decr_buf + bytes);
1011 bytes += qq_get16(&timeRemainder, decr_buf + bytes); 1010 bytes += qq_get16(&timeRemainder, decr_buf + bytes);
1012 purple_debug(PURPLE_DEBUG_INFO, "QQ", 1011 purple_debug(PURPLE_DEBUG_INFO, "QQ",
1013 "Level uid: %d, onlineTime: %d, level: %d, timeRemainder: %d\n", 1012 "Level packet entry:\nuid: %d\nonlineTime: %d\nlevel: %d\ntimeRemainder: %d\n",
1014 uid, onlineTime, level, timeRemainder); 1013 uid, onlineTime, level, timeRemainder);
1015 purple_name = uid_to_purple_name(uid); 1014 purple_name = uid_to_purple_name(uid);
1016 b = purple_find_buddy(account, purple_name); 1015 b = purple_find_buddy(account, purple_name);
1017 q_bud = (b == NULL) ? NULL : (qq_buddy *) b->proto_data; 1016 q_bud = (b == NULL) ? NULL : (qq_buddy *) b->proto_data;
1018 1017

mercurial