Mercurial > pidgin.yaz
diff src/gtkconv.c @ 4785:1e28e7d802a1
[gaim-migrate @ 5105]
fix a few things, get rid of a few stale functions, and get rid of the
compatibility functions. wee!
committer: Tailor Script <tailor@pidgin.im>
author | Nathan Walp <nwalp@pidgin.im> |
---|---|
date | Sat, 15 Mar 2003 03:23:30 +0000 |
parents | b6f33ba0a0c0 |
children | 01e349782075 |
line wrap: on
line diff
--- a/src/gtkconv.c Sat Mar 15 01:07:08 2003 +0000 +++ b/src/gtkconv.c Sat Mar 15 03:23:30 2003 +0000 @@ -2202,8 +2202,7 @@ static GList * generate_invite_user_names(struct gaim_connection *gc) { - GSList *grp = gaim_blist_groups(), *grp1; - GSList *bl, *bl1; + GaimBlistNode *gnode,*bnode; struct group *g; struct buddy *buddy; static GList *tmp = NULL; @@ -2214,18 +2213,19 @@ tmp = g_list_append(NULL, ""); if (gc != NULL) { - for (grp1 = grp; grp1 != NULL; grp1 = grp1->next) { - g = (struct group *)grp1->data; - bl = gaim_blist_members(g); - for (bl1 = bl; bl1 != NULL; bl1 = bl1->next) { - buddy = (struct buddy *)bl1->data; - - if (buddy->present) + for(gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) { + if(!GAIM_BLIST_NODE_IS_GROUP(gnode)) + continue; + g = (struct group *)gnode; + for(bnode = gnode->child; bnode; bnode = bnode->next) { + if(!GAIM_BLIST_NODE_IS_BUDDY(bnode)) + continue; + buddy = (struct buddy *)bnode; + + if (buddy->account == gc->account && buddy->present) tmp = g_list_append(tmp, buddy->name); } - g_slist_free(bl); } - g_slist_free(grp); } return tmp;