1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-27 21:36:37 +02:00

Allow channel argument without user/host for IRC command /ban

This commit is contained in:
Sebastien Helleu
2010-12-02 12:10:04 +01:00
parent 443b6962b4
commit e2be1dbd43
+15 -6
View File
@@ -634,14 +634,23 @@ irc_command_ban (void *data, struct t_gui_buffer *buffer, int argc,
return WEECHAT_RC_OK;
}
}
/* loop on users */
while (argv[pos_args])
if (argv[pos_args])
{
/* loop on users */
while (argv[pos_args])
{
irc_server_sendf (ptr_server, IRC_SERVER_SEND_OUTQ_PRIO_HIGH, NULL,
"MODE %s +b %s",
pos_channel, argv[pos_args]);
pos_args++;
}
}
else
{
irc_server_sendf (ptr_server, IRC_SERVER_SEND_OUTQ_PRIO_HIGH, NULL,
"MODE %s +b %s",
pos_channel, argv[pos_args]);
pos_args++;
"MODE %s +b",
pos_channel);
}
}
else