From 5e98ff07af5a8d89b7c813f55dfd0972fca11297 Mon Sep 17 00:00:00 2001 From: Wilmer van der Gaast Date: Sat, 17 Jul 2010 15:23:20 +0100 Subject: Free a user structure when using the remove command. This disappeared while most IM modules don't call back when a removal was successful. --- root_commands.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'root_commands.c') diff --git a/root_commands.c b/root_commands.c index f4bb4b82..e9b0e0ab 100644 --- a/root_commands.c +++ b/root_commands.c @@ -643,7 +643,8 @@ static void cmd_remove( irc_t *irc, char **cmd ) bu->ic->acc->prpl->remove_buddy( bu->ic, bu->handle, NULL ); nick_del( bu ); - //TODO(wilmer): bee_user_free() and/or let the IM mod do it? irc_user_free( irc, cmd[1] ); + if( g_slist_find( irc->users, iu ) ) + bee_user_free( irc->b, bu ); irc_usermsg( irc, "Buddy `%s' (nick %s) removed from contact list", s, cmd[1] ); g_free( s ); -- cgit v1.2.3