From eabc9d2c1b1d29aeb47162da64ce2b607c3d43ff Mon Sep 17 00:00:00 2001 From: Wilmer van der Gaast Date: Mon, 12 Apr 2010 00:49:32 +0200 Subject: Fixed cleanup issues when turning off an account. Also fixed syntax of *_user_free(). --- irc_user.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'irc_user.c') diff --git a/irc_user.c b/irc_user.c index 8ad20b54..b7629490 100644 --- a/irc_user.c +++ b/irc_user.c @@ -46,12 +46,11 @@ irc_user_t *irc_user_new( irc_t *irc, const char *nick ) return iu; } -int irc_user_free( irc_t *irc, const char *nick ) +int irc_user_free( irc_t *irc, irc_user_t *iu ) { - irc_user_t *iu; GSList *l; - if( !( iu = irc_user_by_name( irc, nick ) ) ) + if( !iu ) return 0; irc->users = g_slist_remove( irc->users, iu ); -- cgit v1.2.3