diff src/blist.c @ 6731:b4943b9cea2b

[gaim-migrate @ 7258] No more buddy list weird duplication when dragging the first contact in a group committer: Tailor Script <tailor@pidgin.im>
author Nathan Walp <nwalp@pidgin.im>
date Wed, 03 Sep 2003 13:08:07 +0000
parents 854a435d2cc3
children d93c6a1fadf2
line wrap: on
line diff
--- a/src/blist.c	Wed Sep 03 12:46:05 2003 +0000
+++ b/src/blist.c	Wed Sep 03 13:08:07 2003 +0000
@@ -704,11 +704,8 @@
 	cnode = (GaimBlistNode*)contact;
 
 	if(cnode->parent) {
-
-		ops->remove(gaimbuddylist, cnode);
-
-		if(gnode->child == cnode)
-			gnode->child = cnode->next;
+		if(cnode->parent->child == cnode)
+			cnode->parent->child = cnode->next;
 		if(cnode->prev)
 			cnode->prev->next = cnode->next;
 		if(cnode->next)
@@ -721,6 +718,8 @@
 			((GaimGroup*)cnode->parent)->currentsize--;
 		((GaimGroup*)cnode->parent)->totalsize--;
 
+		ops->remove(gaimbuddylist, cnode);
+
 		save = TRUE;
 	}