# HG changeset patch # User Richard Nelson # Date 1180058766 0 # Node ID 29b3dc9cc8c581961d5eba176dc8bcbb588967ee # Parent 99a2add7c4f262956eec67e9ac4a5876ff38d46e It's valid for different types to be compared. In that case, use existing positions. diff -r 99a2add7c4f2 -r 29b3dc9cc8c5 finch/gntblist.c --- a/finch/gntblist.c Fri May 25 00:55:40 2007 +0000 +++ b/finch/gntblist.c Fri May 25 02:06:06 2007 +0000 @@ -1873,9 +1873,10 @@ const char *s1, *s2; char *us1, *us2; int ret; - - g_return_val_if_fail(n1->type == n2->type, -1); - + + if (n1->type != n2->type) + return blist_node_compare_position(n1, n2); + switch (n1->type) { case PURPLE_BLIST_CHAT_NODE: @@ -1908,7 +1909,8 @@ { int ret; - g_return_val_if_fail(n1->type == n2->type, -1); + if (n1->type != n2->type) + return blist_node_compare_position(n1, n2); switch (n1->type) { case PURPLE_BLIST_CONTACT_NODE: @@ -1952,7 +1954,8 @@ int ret; PurpleBuddy *b1, *b2; - g_return_val_if_fail(n1->type == n2->type, -1); + if (n1->type != n2->type) + return blist_node_compare_position(n1, n2); switch (n1->type) { case PURPLE_BLIST_BUDDY_NODE: