irctk

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

commit dcd18b50396912a2aa5bc8c43d7091898e11e7a7
parent c902bee40c1535f690fbdf17b3cc5256adb57200
Author: Antoine Amarilli <a3nm@a3nm.net>
Date:   Wed, 11 Jul 2012 22:42:29 +0200

handle more errors

Diffstat:
irctk.c | 4++++
1 file changed, 4 insertions(+), 0 deletions(-)

diff --git a/irctk.c b/irctk.c @@ -1288,6 +1288,10 @@ void manage_event (irc_session_t *session, const char *event, const char *origin // TODO report name of channel last joined, die if it was the one specified // on CLI info("Cannot join channel: bad password."); + } else if (atoi(event) == LIBIRC_RFC_ERR_NOSUCHCHANNEL) { + info("Cannot join channel: no such channel."); + } else if (atoi(event) == LIBIRC_RFC_ERR_TOOMANYCHANNELS) { + info("Cannot join channel: you have joined too many channels."); } else if (atoi(event) == LIBIRC_RFC_ERR_INVITEONLYCHAN) { info("Cannot join channel: channel is invite-only."); } else if (atoi(event) == ERR_BADCHANNAME) {