pidgin: 3c1dec61: Don't crash if user == NULL in a couple ...
qulogic at pidgin.im
qulogic at pidgin.im
Tue Aug 26 00:36:00 EDT 2008
-----------------------------------------------------------------
Revision: 3c1dec61837db8f0f51fc35f7ca26ff948a4e4f4
Ancestor: 710f38b975eaf7565ddfa8389153489ce33c6d31
Author: qulogic at pidgin.im
Date: 2008-08-26T02:24:17
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/3c1dec61837db8f0f51fc35f7ca26ff948a4e4f4
Modified files:
libpurple/protocols/msn/user.c
ChangeLog:
Don't crash if user == NULL in a couple more places. Not exactly the
real cause, but fixes #6777.
-------------- next part --------------
============================================================
--- libpurple/protocols/msn/user.c 81de621eb57b5b26774d00ffbf460c47e9a3f463
+++ libpurple/protocols/msn/user.c 6400e7b9b6da1e86d19f1884a1a0775dd5ba8315
@@ -84,6 +84,8 @@ msn_user_update(MsnUser *user)
PurpleAccount *account;
gboolean offline;
+ g_return_if_fail(user != NULL);
+
account = user->userlist->session->account;
offline = (user->status == NULL);
@@ -125,6 +127,8 @@ msn_user_set_state(MsnUser *user, const
{
const char *status;
+ g_return_if_fail(user != NULL);
+
if (state == NULL) {
user->status = NULL;
return;
@@ -282,7 +286,7 @@ msn_user_is_online(PurpleAccount *accoun
{
PurpleBuddy *buddy;
- buddy =purple_find_buddy(account,name);
+ buddy = purple_find_buddy(account, name);
return PURPLE_BUDDY_IS_ONLINE(buddy);
}
More information about the Commits
mailing list