From 8d93b4ad430af75e8ca50116cf7a8ddd19084649 Mon Sep 17 00:00:00 2001 From: Wilmer van der Gaast Date: Fri, 22 Oct 2010 01:50:34 +0100 Subject: Oops. Just in time I noticed the whatsnew code doesn't kick in for pre-1.3 accounts. Fixed now. --- root_commands.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'root_commands.c') diff --git a/root_commands.c b/root_commands.c index 98105832..81e33076 100644 --- a/root_commands.c +++ b/root_commands.c @@ -205,6 +205,8 @@ gboolean cmd_identify_finish( gpointer data, gint fd, b_input_condition cond ) static void cmd_register( irc_t *irc, char **cmd ) { + char s[16]; + if( global.conf->authmode == AUTHMODE_REGISTERED ) { irc_usermsg( irc, "This server does not allow registering new accounts" ); @@ -221,6 +223,12 @@ static void cmd_register( irc_t *irc, char **cmd ) irc_setpass( irc, cmd[1] ); irc->status |= USTATUS_IDENTIFIED; irc_umode_set( irc, "+R", 1 ); + + /* Set this var now, or anyone who logs in to his/her + newly created account for the first time gets the + whatsnew story. */ + g_snprintf( s, sizeof( s ), "%d", BITLBEE_VERSION_CODE ); + set_setstr( &irc->b->set, "last_version", s ); break; default: -- cgit v1.2.3