Split RPL_APASSWARN and ERR_NOTMANAGER into multiple messages to avoid
[ircu2.10.12-pk.git] / ircd / s_err.c
index 23137fd022db16c00390ed6857fda8eb0a9bab1e..45a34daaff53f99b5eec2b01fc52f78a112e74fc 100644 (file)
 #include "config.h"
 
 #include "numeric.h"
+#include "ircd_log.h"
 #include "s_debug.h"
 
-#include <assert.h>
+/* #include <assert.h> -- Now using assert in ircd_log.h */
 #include <string.h>
 
 /** Array of Numeric replies, indexed by numeric. */
@@ -49,13 +50,9 @@ static Numeric replyTable[] = {
 /* 008 */
   { RPL_SNOMASK, "%d :: Server notice mask (%#x)", "008" },
 /* 009 */
-  { RPL_STATMEMTOT, "%u %u :Bytes Blocks", "009" },
+  { 0 },
 /* 010 */
-#ifdef MEMSIZESTATS
-  { RPL_STATMEM, "%u %u %s %u", "010" },
-#else
-  { RPL_STATMEM, "%u %u %s", "010" },
-#endif
+  { 0 },
 /* 011 */
   { 0 },
 /* 012 */
@@ -95,11 +92,11 @@ static Numeric replyTable[] = {
 /* 029 */
   { 0 },
 /* 030 */
-  { RPL_APASSWARN, ":%s%s%s%s%s", "030" },
+  { RPL_APASSWARN_SET, ":Channel Admin password (+A) set to '%s'.  Are you SURE you want to use this as Admin password? You will NOT be able to change this password anymore once the channel is more than 48 hours old!", "030" },
 /* 031 */
-  { 0 },
+  { RPL_APASSWARN_SECRET, ":Use \"/MODE %s -A %s\" to remove the password and then immediately set a new one.  IMPORTANT: YOU CANNOT RECOVER THIS PASSWORD, EVER; WRITE THE PASSWORD DOWN (don't store this rescue password on disk)! Now set the channel user password (+U).", "031" },
 /* 032 */
-  { 0 },
+  { RPL_APASSWARN_CLEAR, ":WARNING: You removed the channel Admin password (+A). If you disconnect or leave the channel without setting a new password then you will not be able to set it again!  SET A NEW PASSWORD NOW!", "032" },
 /* 033 */
   { 0 },
 /* 034 */
@@ -461,11 +458,11 @@ static Numeric replyTable[] = {
 /* 212 */
   { RPL_STATSCOMMANDS, "%s %u %u", "212" },
 /* 213 */
-  { RPL_STATSCLINE, "%c %s * %s %d %s", "213" },
+  { RPL_STATSCLINE, "C %s %s%s %d %d %s %s", "213" },
 /* 214 */
-  { RPL_STATSNLINE, "%c %s * %s %d %d", "214" },
+  { 0 },
 /* 215 */
-  { RPL_STATSILINE, "%c %s %s %s %d %s", "215" },
+  { RPL_STATSILINE, "I %s %d %s%s %d %s", "215" },
 /* 216 */
   { RPL_STATSKLINE, "%c %s \"%s\" %s 0 0", "216" },
 /* 217 */
@@ -479,7 +476,7 @@ static Numeric replyTable[] = {
 /* 221 */
   { RPL_UMODEIS, "%s", "221" },
 /* 222 */
-  { 0 },
+  { RPL_STATSJLINE, "J %s", "222" },
 /* 223 */
   { 0 },
 /* 224 */
@@ -517,13 +514,13 @@ static Numeric replyTable[] = {
 /* 240 */
   { 0 },
 /* 241 */
-  { RPL_STATSLLINE, "%c %s * %s %d %d", "241" },
+  { RPL_STATSLLINE, "Module Description EntryPoint", "241" },
 /* 242 */
   { RPL_STATSUPTIME, ":Server Up %d days, %d:%02d:%02d", "242" },
 /* 243 */
-  { RPL_STATSOLINE, "%c %s * %s %d %d", "243" },
+  { RPL_STATSOLINE, "O %s@%s * %s %s", "243" },
 /* 244 */
-  { RPL_STATSHLINE, "%c %s * %s %d %d", "244" },
+  { 0 },
 /* 245 */
   { 0 },
 /* 246 */
@@ -531,7 +528,7 @@ static Numeric replyTable[] = {
 /* 247 */
   { RPL_STATSGLINE, "%c %s%s%s %Tu :%s", "247" },
 /* 248 */
-  { RPL_STATSULINE, "%c %s %s %s %d %d", "248" },
+  { RPL_STATSULINE, "U %s", "248" },
 /* 249 */
   { RPL_STATSDEBUG, 0, "249" },
 /* 250 */
@@ -577,7 +574,7 @@ static Numeric replyTable[] = {
 /* 270 */
   { RPL_PRIVS, "%s :", "270" },
 /* 271 */
-  { RPL_SILELIST, "%s %s", "271" },
+  { RPL_SILELIST, "%s %s%s", "271" },
 /* 272 */
   { RPL_ENDOFSILELIST, "%s :End of Silence List", "272" },
 /* 273 */
@@ -855,7 +852,7 @@ static Numeric replyTable[] = {
 /* 409 */
   { ERR_NOORIGIN, ":No origin specified", "409" },
 /* 410 */
-  { 0 },
+  { ERR_UNKNOWNCAPCMD, "%s :Unknown CAP subcommand", "410" },
 /* 411 */
   { ERR_NORECIPIENT, ":No recipient given (%s)", "411" },
 /* 412 */
@@ -1137,7 +1134,7 @@ static Numeric replyTable[] = {
 /* 550 */
   { ERR_NOTLOWEROPLEVEL, "%s %s %hu %hu :Cannot %s someone with %s op-level", "550" },
 /* 551 */
-  { ERR_NOTMANAGER, "%s :You must be channel Admin to add or remove a password. %s %s %s", "551" },
+  { ERR_NOTMANAGER, "%s :You must be channel Admin to add or remove a password. Use /JOIN %s <AdminPass>.", "551" },
 /* 552 */
   { ERR_CHANSECURED, "%s :Channel is older than 48 hours and secured. Cannot change Admin pass anymore", "552" },
 /* 553 */
@@ -1145,9 +1142,9 @@ static Numeric replyTable[] = {
 /* 554 */
   { ERR_UPASSNOTSET, "%s :Cannot set user pass (+U) until Admin pass (+A) is set.  First use /MODE %s +A <adminpass>", "554" },
 /* 555 */
-  { 0 },
+  { ERR_NOMANAGER_LONG, "%s :Re-create the channel.  The channel must be *empty* for 48 continuous hours before it can be recreated.", "555" },
 /* 556 */
-  { 0 },
+  { ERR_NOMANAGER_SHORT, "%s :Re-create the channel.  The channel must be *empty* for a minute or two before it can be recreated.", "556" },
 /* 557 */
   { 0 },
 /* 558 */