Mercurial > pidgin.yaz
diff src/protocols/yahoo/yahoo.c @ 4775:92ae181271e9
[gaim-migrate @ 5095]
This fixes a bug when adding a jabber dude to a new group, I think. I
dunno, it might fix some other stuff.
If Gaim were any less inanimate I would try to sleep with it so bad
it's not even funny.
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Fri, 14 Mar 2003 17:06:00 +0000 |
parents | 01cae9259e2f |
children | e23a7e166680 |
line wrap: on
line diff
--- a/src/protocols/yahoo/yahoo.c Fri Mar 14 16:18:51 2003 +0000 +++ b/src/protocols/yahoo/yahoo.c Fri Mar 14 17:06:00 2003 +0000 @@ -446,6 +446,8 @@ { GSList *l = pkt->hash; gboolean export = FALSE; + struct buddy *b; + struct group *g; while (l) { char **lines; @@ -470,10 +472,13 @@ } buddies = g_strsplit(split[1], ",", -1); for (bud = buddies; bud && *bud; bud++) - if (!gaim_find_buddy(gc->account, *bud)) { - struct buddy *b = gaim_buddy_new(gc->account, *bud, NULL); - struct group *g = gaim_group_new(split[0]); - gaim_blist_add_buddy(b,g,NULL); + if (!(b = gaim_find_buddy(gc->account, *bud))) { + if (!(g = gaim_find_group(split[0]))) { + g = gaim_group_new(split[0]); + gaim_blist_add_group(g, NULL); + } + b = gaim_buddy_new(gc->account, *bud, NULL); + gaim_blist_add_buddy(b, g, NULL); export = TRUE; } g_strfreev(buddies);