# HG changeset patch # User Christian Hammond # Date 1060025346 0 # Node ID 773b8ce563f5673daedf0a8d5726a9c0c91eb7d5 # Parent 72bbe310ac77282a94c713c918a26689b85561e1 [gaim-migrate @ 6871] The patch to remove buddies when deleting an account needs to be re-thought. The code was put in the gaim_account_destroy() function, which is being called at shutdown, or if it's not, it's supposed to be... I don't want to lose my whole buddy list. committer: Tailor Script diff -r 72bbe310ac77 -r 773b8ce563f5 src/account.c --- a/src/account.c Mon Aug 04 17:44:19 2003 +0000 +++ b/src/account.c Mon Aug 04 19:29:06 2003 +0000 @@ -147,8 +147,6 @@ void gaim_account_destroy(GaimAccount *account) { - GaimBlistNode *gnode, *bnode; - g_return_if_fail(account != NULL); gaim_debug(GAIM_DEBUG_INFO, "account", @@ -160,25 +158,6 @@ gaim_debug(GAIM_DEBUG_INFO, "account", "Continuing to destroy account %p\n", account); - /* Let's remove the buddies for this account, before they cause trouble */ - for(gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) { - if(!GAIM_BLIST_NODE_IS_GROUP(gnode)) - continue; - for(bnode = gnode->child; bnode; bnode=bnode->next) { - if(GAIM_BLIST_NODE_IS_BUDDY(bnode)) { - struct buddy *b = (struct buddy *)bnode; - if(b->account == account) - gaim_blist_remove_buddy(b); - } else if(GAIM_BLIST_NODE_IS_CHAT(bnode)) { - struct chat *c = (struct chat *)bnode; - if(c->account == account) - gaim_blist_remove_chat(c); - } - } - } - - gaim_blist_save(); - if (account->username != NULL) g_free(account->username); if (account->alias != NULL) g_free(account->alias); if (account->password != NULL) g_free(account->password);