irctk

libircclient binding for scripts
git clone https://a3nm.net/git/irctk/
Log | Files | Refs | README

commit c30c836876c44773c21172444328143d60df9490
parent 3c497099822920b38c34fb62b95465d988832d96
Author: Antoine Amarilli <a3nm@a3nm.net>
Date:   Tue,  7 Aug 2012 22:00:15 +0200

fix /quit reason and /part, fix test/events.sh

Diffstat:
irctk.c | 4++--
test/events.sh | 2+-
2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/irctk.c b/irctk.c @@ -1027,7 +1027,7 @@ int do_cmd_msg(irc_session_t *s, char *chan, char* line) if (!*arg || *arg == '\n') { rsl = irc_cmd_part(s, chan); } else if (*arg == ' ') { - rsl = irc_cmd_part(s, arg); + rsl = irc_cmd_part(s, arg + 1); } else { info("Unrecognized command: %s", line); } @@ -1060,7 +1060,7 @@ int do_cmd_msg(irc_session_t *s, char *chan, char* line) } else if ((arg = MATCH_CMD0(line, "quit"))) { char *rquit = NULL; if (*arg == ' ') { - rquit = arg; + rquit = arg + 1; } rsl = irc_cmd_quit(s, rquit); if (!rsl) diff --git a/test/events.sh b/test/events.sh @@ -33,7 +33,7 @@ cat > ref_message <<EOF [#test2] -!- command was kicked from #test2 by op2 (kickarg) [#test2] <op2> hello [#test2] <op2> /hello2 -[] -!- op2 has quit (Client closed connection) +[] -!- op2 has quit ("quitarg") EOF cat > ref_command <<EOF [#test1] <command> /join #test1