diff src/blist.c @ 7826:5ba07997ade3

[gaim-migrate @ 8478] there's no need to keep this around committer: Tailor Script <tailor@pidgin.im>
author Nathan Walp <nwalp@pidgin.im>
date Wed, 10 Dec 2003 07:37:13 +0000
parents d2710b3dcc5c
children 64d1a90f5a78
line wrap: on
line diff
--- a/src/blist.c	Wed Dec 10 06:45:32 2003 +0000
+++ b/src/blist.c	Wed Dec 10 07:37:13 2003 +0000
@@ -127,8 +127,8 @@
 
 static void gaim_contact_compute_priority_buddy(GaimContact *contact) {
 	GaimBlistNode *bnode;
+	int contact_score = INT_MAX;
 	contact->priority = NULL;
-	contact->score = INT_MAX;
 
 	for(bnode = ((GaimBlistNode*)contact)->child; bnode; bnode = bnode->next) {
 		GaimBuddy *buddy;
@@ -149,12 +149,12 @@
 
 		score += gaim_account_get_int(buddy->account, "score", 0);
 
-		if (score < contact->score) {
+		if (score < contact_score) {
 			contact->priority = buddy;
-			contact->score = score;
+			contact_score = score;
 		}
 		if (gaim_prefs_get_bool("/core/contact/last_match"))
-			if (score == contact->score)
+			if (score == contact_score)
 				contact->priority = buddy;
 	}
 }
@@ -765,7 +765,6 @@
 	((GaimBlistNode*)c)->type = GAIM_BLIST_CONTACT_NODE;
 
 	c->totalsize = c->currentsize = c->online = 0;
-	c->score = INT_MAX;
 	gaim_blist_node_initialize_settings((GaimBlistNode*)c);
 
 	ops = gaim_blist_get_ui_ops();