+2007-05-28 Michael Poole <mdpoole@troilus.org>
+
+ * include/numeric.h (ERR_INPUTTOOLONG): New numeric.
+
+ * ircd/s_bsd.c (read_packet): Use it.
+
+ * ircd/s_err.c (replyTable): Give it a format string.
+
2007-05-20 Michael Poole <mdpoole@troilus.org>
* ircd/m_burst.c (ms_burst): Do not let bursting servers join a
/* ERR_BADMASK 415 IRCnet extension */
#define ERR_QUERYTOOLONG 416 /* Undernet extension */
/* ERR_TOOMANYMATCHES 416 IRCnet extension */
+#define ERR_INPUTTOOLONG 417
/* ERR_LENGTHTRUNCATED 419 aircd */
#define ERR_UNKNOWNCOMMAND 421
if (DBufLength(&(cli_recvQ(cptr))) < 510)
SetFlag(cptr, FLAG_NONL);
else
+ {
+ /* More than 512 bytes in the line - drop the input and yell
+ * at the client.
+ */
DBufClear(&(cli_recvQ(cptr)));
+ send_reply(cptr, ERR_INPUTTOOLONG);
+ }
}
else if (client_dopacket(cptr, dolen) == CPTR_KILLED)
return CPTR_KILLED;
/* 416 */
{ ERR_QUERYTOOLONG, "%s :Too many lines in the output, restrict your query", "416" },
/* 417 */
- { 0 },
+ { ERR_INPUTTOOLONG, ":Input line was too long", "417" },
/* 418 */
{ 0 },
/* 419 */