diff options
author | Jilles Tjoelker <jilles@irssi.org> | 2008-11-28 20:43:59 +0000 |
---|---|---|
committer | jilles <jilles@dbcabf3a-b0e7-0310-adc4-f8d773084564> | 2008-11-28 20:43:59 +0000 |
commit | 3ddd984bfc9f9c991e168ebf938163772058f2c6 (patch) | |
tree | 5d024cf9530b1548f3d757c16cad1c5ef3ba6274 /src/fe-common/irc/fe-irc-commands.c | |
parent | 6fe433ca0bfabd99c63537f356962ba0523e3385 (diff) | |
download | irssi-3ddd984bfc9f9c991e168ebf938163772058f2c6.zip |
Allow /ban, /unban, /kickban, /knockout if channel is not synced.
Requesting ban lists from an unsynced channel will ask
them from the server, banning a user whose u@h irssi
does not know will ban nick!*@* and only bans irssi
knows about can be removed.
git-svn-id: file:///var/www/svn.irssi.org/SVN/irssi/trunk@4925 dbcabf3a-b0e7-0310-adc4-f8d773084564
Diffstat (limited to 'src/fe-common/irc/fe-irc-commands.c')
-rw-r--r-- | src/fe-common/irc/fe-irc-commands.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/fe-common/irc/fe-irc-commands.c b/src/fe-common/irc/fe-irc-commands.c index 6f208447..c9a9016e 100644 --- a/src/fe-common/irc/fe-irc-commands.c +++ b/src/fe-common/irc/fe-irc-commands.c @@ -211,9 +211,6 @@ static void bans_show_channel(IRC_CHANNEL_REC *channel, IRC_SERVER_REC *server) GSList *tmp; int counter; - if (!channel->synced) - cmd_return_error(CMDERR_CHAN_NOT_SYNCED); - if (channel->banlist == NULL) { printformat(server, channel->visible_name, MSGLEVEL_CLIENTNOTICE, @@ -265,9 +262,9 @@ static void cmd_ban(const char *data, IRC_SERVER_REC *server, if (*channel != '\0' && strcmp(channel, "*") != 0) chanrec = irc_channel_find(server, channel); - if (chanrec == NULL) { - /* not joined to such channel, - but ask ban lists from server */ + if (chanrec == NULL || !chanrec->synced) { + /* not joined to such channel or not yet synced, + ask ban lists from server */ bans_ask_channel(channel, server, item); } else { bans_show_channel(chanrec, server); |