From 7b59872d86160099968d0f8cdafc2853b074d39b Mon Sep 17 00:00:00 2001 From: Wilmer van der Gaast Date: Tue, 13 Apr 2010 02:04:55 +0200 Subject: Support for simple VERSION/PING CTCPs to root. --- irc_user.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'irc_user.c') diff --git a/irc_user.c b/irc_user.c index cf1d1e3e..7b2d4be1 100644 --- a/irc_user.c +++ b/irc_user.c @@ -150,6 +150,13 @@ static gboolean root_ctcp( irc_user_t *iu, char * const *ctcp ) { if( g_strcasecmp( ctcp[0], "VERSION" ) == 0 ) { + irc_send_msg_f( iu, "NOTICE", iu->irc->user->nick, "\001%s %s\001", + ctcp[0], "BitlBee " BITLBEE_VERSION " " ARCH "/" CPU ); + } + else if( g_strcasecmp( ctcp[0], "PING" ) == 0 ) + { + irc_send_msg_f( iu, "NOTICE", iu->irc->user->nick, "\001%s %s\001", + ctcp[0], ctcp[1] ? : "" ); } return TRUE; -- cgit v1.2.3