Changeset 9b69eb7


Ignore:
Timestamp:
2010-03-27T12:34:44Z (15 years ago)
Author:
Wilmer van der Gaast <wilmer@…>
Branches:
master
Children:
b919363
Parents:
83e92bf
Message:

MOTD command added since, well, I had all the code for it already anyway.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • irc_commands.c

    r83e92bf r9b69eb7  
    179179}
    180180
     181static void irc_cmd_motd( irc_t *irc, char **cmd )
     182{
     183        irc_send_motd( irc );
     184}
     185
    181186#if 0
    182187//#if 0
     
    244249static void irc_cmd_privmsg( irc_t *irc, char **cmd )
    245250{
    246         if ( !cmd[2] )
     251        if( !cmd[2] )
    247252        {
    248253                irc_send_num( irc, 412, ":No text to send" );
    249254        }
    250         else if ( irc->nick && g_strcasecmp( cmd[1], irc->nick ) == 0 )
     255        else if( irc->nick && g_strcasecmp( cmd[1], irc->nick ) == 0 )
    251256        {
    252257                irc_write( irc, ":%s!%s@%s %s %s :%s", irc->nick, irc->user, irc->host, cmd[0], cmd[1], cmd[2] );
     
    502507        /* [TV] This aliases the NS command to PRIVMSG root as well */
    503508        root_command( irc, cmd + 1 );
    504 }
    505 
    506 static void irc_cmd_motd( irc_t *irc, char **cmd )
    507 {
    508         irc_motd( irc );
    509509}
    510510
     
    565565        { "whois",       1, irc_cmd_whois,       IRC_CMD_LOGGED_IN },
    566566        { "whowas",      1, irc_cmd_whowas,      IRC_CMD_LOGGED_IN },
     567        { "motd",        0, irc_cmd_motd,        IRC_CMD_LOGGED_IN },
    567568#if 0
    568569        { "oper",        2, irc_cmd_oper,        IRC_CMD_LOGGED_IN },
     
    579580        { "nickserv",    1, irc_cmd_nickserv,    IRC_CMD_LOGGED_IN },
    580581        { "ns",          1, irc_cmd_nickserv,    IRC_CMD_LOGGED_IN },
    581         { "motd",        0, irc_cmd_motd,        IRC_CMD_LOGGED_IN },
    582582        { "pong",        0, irc_cmd_pong,        IRC_CMD_LOGGED_IN },
    583583        { "version",     0, irc_cmd_version,     IRC_CMD_LOGGED_IN },
Note: See TracChangeset for help on using the changeset viewer.