Mercurial > pidgin.yaz
changeset 17297:29b3dc9cc8c5
It's valid for different types to be compared. In that case, use existing positions.
author | Richard Nelson <wabz@pidgin.im> |
---|---|
date | Fri, 25 May 2007 02:06:06 +0000 |
parents | 99a2add7c4f2 |
children | f9838075117a |
files | finch/gntblist.c |
diffstat | 1 files changed, 8 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- 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: