diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/irc.c | 30 |
1 files changed, 13 insertions, 17 deletions
@@ -152,7 +152,7 @@ static void print_ctcp(void) { } /* FIXME: this isn't very fast */ -static void do_ctcp(int is_notice) { +static void do_ctcp(char is_notice) { static char *p, *ctcp_type, *resp; resp = 0; @@ -330,25 +330,10 @@ static void do_kick(void) { print_reason(); } -static void do_mode(void) { - int i; - if(msg_src) - scr_print_active(msg_src); - else - scr_print_active("Server"); - scr_print_active(" sets mode: "); - for(i = 0; i < msg_argcount; i++) { - scr_print_active(msg_args[i]); - scr_putc_active(' '); - } - if(msg_text) scr_print_active(msg_text); - scr_eol_active(); -} - /* numerics call this with arg==1, since arg 0 is always our nick. other commands call with arg==0 to print everything. */ -static void do_catchall(int arg) { +static void do_catchall(char arg) { if(msg_src) { scr_print_active(msg_src); scr_putc_active(' '); @@ -368,6 +353,17 @@ static void do_catchall(int arg) { scr_eol_active(); } +static void do_mode(void) { + if(msg_src) { + scr_print_active(msg_src); + msg_src = 0; /* don't let do_catchall() print it again */ + } else { + scr_print_active("Server"); + } + scr_print_active(" sets mode:"); + do_catchall(0); +} + /* permutes last character (doesn't add one), so for "Bob" you get: Bo_, Bo1 through Bo9, BoA through BoZ Gives a total of 36 replacement nicks to try. |
