diff options
author | Wilmer van der Gaast <wilmer@gaast.net> | 2010-07-29 20:18:54 +0200 |
---|---|---|
committer | Wilmer van der Gaast <wilmer@gaast.net> | 2010-07-29 20:18:54 +0200 |
commit | f7ca5877b69d452ef2e2ab4dc4d06743072deca0 (patch) | |
tree | 6ce785e43326ef0b638105eaf4ccc2b1760bfc43 /root_commands.c | |
parent | 2fe5eb939ff77697b578bf45ba23cd99daee9c5f (diff) |
Restore default_target setting, kill last_root_cmd variable and just use
the last_channel variable, like for any other user.
Diffstat (limited to 'root_commands.c')
-rw-r--r-- | root_commands.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/root_commands.c b/root_commands.c index 69aa3e98..fe445d26 100644 --- a/root_commands.c +++ b/root_commands.c @@ -559,9 +559,9 @@ static void cmd_channel( irc_t *irc, char **cmd ) { /* If this doesn't match any channel, maybe this is the short syntax (only works when used inside a channel). */ - if( ( len = strlen( cmd[1] ) ) && - g_strncasecmp( cmd[1], "set", len ) == 0 && - ( ic = irc_channel_by_name( irc, irc->last_root_cmd ) ) ) + if( ( ic = irc->root->last_channel ) && + ( len = strlen( cmd[1] ) ) && + g_strncasecmp( cmd[1], "set", len ) == 0 ) cmd_set_real( irc, cmd + 1, &ic->set, NULL ); else irc_usermsg( irc, "Could not find channel `%s'", cmd[1] ); @@ -641,7 +641,7 @@ static void cmd_add( irc_t *irc, char **cmd ) irc_channel_t *ic; char *s, *group = NULL;; - if( ( ic = irc_channel_by_name( irc, irc->last_root_cmd ) ) && + if( ( ic = irc->root->last_channel ) && ( s = set_getstr( &ic->set, "fill_by" ) ) && strcmp( s, "group" ) == 0 && ( group = set_getstr( &ic->set, "group" ) ) ) |