Remove unnecssary space at the start of SERVER_NOTICE_* formats

Also fix up similar hardcoded formats in notice.c.

The space isn't needed because serversay() adds a space (and has done for
a very long time).
This commit is contained in:
Kevin Easton
2016-04-14 22:22:05 +10:00
parent d236b19410
commit 6b0aa0f8fe
2 changed files with 32 additions and 33 deletions

View File

@@ -131,7 +131,7 @@
#define DEFAULT_FORMAT_MSG_FSET "%K[%P$1%K(%p$2%K)]%n $3-"
#define DEFAULT_FORMAT_MSG_AR_FSET "%K[%Y$1%K(%Y$2%K)]%n $3-"
#define DEFAULT_FORMAT_OPER_FSET "%C$1 %K[%c$2%K]%n )s now %Wan%w %GIRC%n whore"
#define DEFAULT_FORMAT_OPER_FSET "%C$1 %K[%c$2%K]%n is now %Wan%w %GIRC%n whore"
#define DEFAULT_FORMAT_IGNORE_INVITE_FSET "%K>%n>%W> You have been invited to $1-"
#define DEFAULT_FORMAT_IGNORE_MSG_FSET "%K[%P$1%P$2%K(%p$3%K)]%n $4-"
@@ -227,7 +227,6 @@
#define DEFAULT_FORMAT_SERVER_MSG2_FROM_FSET "$G%n $1-"
#define DEFAULT_FORMAT_SERVER_NOTICE_FSET "%K[%c***%K] %n$2-"
/*#define DEFAULT_FORMAT_SERVER_NOTICE_FSET "$2-"*/
#define DEFAULT_FORMAT_SERVER_NOTICE_BOT_FSET "Possible bot: %C$1 %K[%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_BOT1_FSET "Possible $1 bot: %C$2 %K[%c$3-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_BOT_ALARM_FSET "$1 alarm activated: %C$2 %K[%c$3-%K]%n"
@@ -563,7 +562,7 @@
#define DEFAULT_FORMAT_MSG_FSET ansi?"%@%K[%P$1%K(%p$2%K)]%n $3-":"%@[$1($2)] $3-"
#define DEFAULT_FORMAT_MSG_AR_FSET ansi?"%@%K[%Y$1%K(%Y$2%K)]%n $3-":"%@[$1($2)] $3-"
#define DEFAULT_FORMAT_OPER_FSET "%C$1 %K[%c$2%K]%n )s now %Wan%w %GIRC%n whore"
#define DEFAULT_FORMAT_OPER_FSET "%C$1 %K[%c$2%K]%n is now %Wan%w %GIRC%n whore"
#define DEFAULT_FORMAT_IGNORE_INVITE_FSET "%K>%n>%W> You have been invited to $1-"
#define DEFAULT_FORMAT_IGNORE_MSG_FSET "%K[%P$1%P$2%K(%p$3%K)]%n $4-"
@@ -656,25 +655,25 @@
#define DEFAULT_FORMAT_SERVER_MSG2_FROM_FSET "$G%n $1-"
#define DEFAULT_FORMAT_SERVER_NOTICE_FSET "$2-"
#define DEFAULT_FORMAT_SERVER_NOTICE_BOT_FSET " Possible bot: %C$1 %K[%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_BOT1_FSET " Possible $1 bot: %C$2 %K[%c$3-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_BOT_ALARM_FSET " $1 alarm activated: %C$2 %K[%c$3-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_CLIENT_CONNECT_FSET " Client Connecting: %C$1 %K[%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_CLIENT_EXIT_FSET " Client Exiting: %C$1 %K[%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_CLIENT_INVALID_FSET " Invalid username: %C$1 %K[%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_CLIENT_TERM_FSET " Terminating client for excess flood %C$1%K [%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_FAKE_FSET " Fake Mode detected on $1 -> $2-"
#define DEFAULT_FORMAT_SERVER_NOTICE_KILL_FSET " Foreign OperKill: %W$1%n killed %c$2%n %K(%n$3-%K)%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_KILL_LOCAL_FSET " Local OperKill: %W$1%n killed %c$2%n %K(%n$3-%K)%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_KLINE_FSET " %W$1%n added a new K-Line %K[%c$2%K]%n for $3-"
#define DEFAULT_FORMAT_SERVER_NOTICE_GLINE_FSET " %W$1%n added a new K-Line %K[%c$2%K]%n from $3 for $4-"
#define DEFAULT_FORMAT_SERVER_NOTICE_NICK_COLLISION_FSET " Nick collision %W$1%n killed %c$2%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_OPER_FSET " %C$1 %K[%c$2%K]%n is now %Wa%w %GIRC%n whore"
#define DEFAULT_FORMAT_SERVER_NOTICE_REHASH_FSET " %W$1%n is rehashing the Server config file"
#define DEFAULT_FORMAT_SERVER_NOTICE_STATS_FSET " Stats $1: %C$2 %K[%c$3-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_TRAFFIC_HIGH_FSET " Entering high-traffic mode %K(%n$1 > $2-%K)%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_TRAFFIC_NORM_FSET " Resuming standard operation %K(%n$1 $2 $3-%K)%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_UNAUTH_FSET " Unauthorized Connection from $1-"
#define DEFAULT_FORMAT_SERVER_NOTICE_BOT_FSET "Possible bot: %C$1 %K[%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_BOT1_FSET "Possible $1 bot: %C$2 %K[%c$3-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_BOT_ALARM_FSET "$1 alarm activated: %C$2 %K[%c$3-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_CLIENT_CONNECT_FSET "Client Connecting: %C$1 %K[%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_CLIENT_EXIT_FSET "Client Exiting: %C$1 %K[%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_CLIENT_INVALID_FSET "Invalid username: %C$1 %K[%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_CLIENT_TERM_FSET "Terminating client for excess flood %C$1%K [%c$2-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_FAKE_FSET "Fake Mode detected on $1 -> $2-"
#define DEFAULT_FORMAT_SERVER_NOTICE_KILL_FSET "Foreign OperKill: %W$1%n killed %c$2%n %K(%n$3-%K)%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_KILL_LOCAL_FSET "Local OperKill: %W$1%n killed %c$2%n %K(%n$3-%K)%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_KLINE_FSET "%W$1%n added a new K-Line %K[%c$2%K]%n for $3-"
#define DEFAULT_FORMAT_SERVER_NOTICE_GLINE_FSET "%W$1%n added a new K-Line %K[%c$2%K]%n from $3 for $4-"
#define DEFAULT_FORMAT_SERVER_NOTICE_NICK_COLLISION_FSET "Nick collision %W$1%n killed %c$2%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_OPER_FSET "%C$1 %K[%c$2%K]%n is now %Wan%w %GIRC%n whore"
#define DEFAULT_FORMAT_SERVER_NOTICE_REHASH_FSET "%W$1%n is rehashing the Server config file"
#define DEFAULT_FORMAT_SERVER_NOTICE_STATS_FSET "Stats $1: %C$2 %K[%c$3-%K]%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_TRAFFIC_HIGH_FSET "Entering high-traffic mode %K(%n$1 > $2-%K)%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_TRAFFIC_NORM_FSET "Resuming standard operation %K(%n$1 $2 $3-%K)%n"
#define DEFAULT_FORMAT_SERVER_NOTICE_UNAUTH_FSET "Unauthorized Connection from $1-"
#define DEFAULT_FORMAT_SET_FSET "%g$[-30.]0 %w$1-"
#define DEFAULT_FORMAT_CSET_FSET "%r$[-14]1 %R$[-20.]0 %w$2-"

View File

@@ -151,14 +151,14 @@ irc.BitchX.com *** Notice -- Nick collision on nickserv(irc.distracted.net <-
if (!(flags & IP_MISMATCH))
goto done;
for_ = line + 14;
serversay(from, "%s", convert_output_format(" IP Mismatch %C$1-", "%s %s", update_clock(GET_TIME), for_));
serversay(from, "%s", convert_output_format("IP Mismatch %C$1-", "%s %s", update_clock(GET_TIME), for_));
}
else if (!strncmp(line, "Hacked ops on opless channel:", 29))
{
if (!(flags & HACK_OPS))
goto done;
for_ = line + 29;
serversay(from, "%s", convert_output_format(" Hacked ops on $0", "%s", for_));
serversay(from, "%s", convert_output_format("Hacked ops on $0", "%s", for_));
}
else if (!strncmp(line, "connect failure:", 16))
{
@@ -167,14 +167,14 @@ irc.BitchX.com *** Notice -- Nick collision on nickserv(irc.distracted.net <-
if (!(flags & SERVER_CRAP))
goto done;
for_ = line + 16;
serversay(from, "%s", convert_output_format(" Connect failure %K[%n$0-%K]", "%s", for_));
serversay(from, "%s", convert_output_format("Connect failure %K[%n$0-%K]", "%s", for_));
}
else if (!strncmp(line, "Identd response differs", 22))
{
if (!(flags & IDENTD))
goto done;
for_ = line + 24;
serversay(from, "%s", convert_output_format(" Identd response differs %K[%C$1-%K]", "%s %s", update_clock(GET_TIME), for_));
serversay(from, "%s", convert_output_format("Identd response differs %K[%C$1-%K]", "%s %s", update_clock(GET_TIME), for_));
}
else if (!strncmp(line, "Fake: ", 6)) /* MODE */
{
@@ -360,7 +360,7 @@ irc.BitchX.com *** Notice -- Nick collision on nickserv(irc.distracted.net <-
if (*temp2 == '(')
temp2++;
}
serversay(from, "%s", convert_output_format(" SQUIT of $1 from $2 %K[%R$3-%K]", "%s %s %s %s", update_clock(GET_TIME), for_, fr, temp2));
serversay(from, "%s", convert_output_format("SQUIT of $1 from $2 %K[%R$3-%K]", "%s %s %s %s", update_clock(GET_TIME), for_, fr, temp2));
}
else if (!strncmp(line, "Received SERVER", 15))
{
@@ -377,7 +377,7 @@ irc.BitchX.com *** Notice -- Nick collision on nickserv(irc.distracted.net <-
if (*temp2 == '(')
temp2++;
}
serversay(from, "%s", convert_output_format(" Received SERVER %c$1%n from %c$2%n %K[%W$3-%K]", "%s %s %s %s", update_clock(GET_TIME), fr, for_, temp2));
serversay(from, "%s", convert_output_format("Received SERVER %c$1%n from %c$2%n %K[%W$3-%K]", "%s %s %s %s", update_clock(GET_TIME), fr, for_, temp2));
}
else if (!strncmp(line, "Sending SQUIT", 13))
{
@@ -390,7 +390,7 @@ irc.BitchX.com *** Notice -- Nick collision on nickserv(irc.distracted.net <-
chop(temp2, 1);
if (*temp2 == '(') temp2++;
}
serversay(from, "%s", convert_output_format(" Sending SQUIT %c$1%n %K[%R$2-%K]", "%s %s %s", update_clock(GET_TIME), fr, temp2));
serversay(from, "%s", convert_output_format("Sending SQUIT %c$1%n %K[%R$2-%K]", "%s %s %s", update_clock(GET_TIME), fr, temp2));
}
else if (!strncmp(line, "Sending SERVER", 14))
{
@@ -403,7 +403,7 @@ irc.BitchX.com *** Notice -- Nick collision on nickserv(irc.distracted.net <-
chop(temp2, 1);
if (*temp2 == '(') temp2++;
}
serversay(from, "%s", convert_output_format(" Sending SERVER %c$1%n %K[%W$2-%K]", "%s %s %s", update_clock(GET_TIME), fr, temp2));
serversay(from, "%s", convert_output_format("Sending SERVER %c$1%n %K[%W$2-%K]", "%s %s %s", update_clock(GET_TIME), fr, temp2));
}
else if (!strncmp(line, "WALLOPS :Remote CONNECT", 23))
{
@@ -414,7 +414,7 @@ irc.BitchX.com *** Notice -- Nick collision on nickserv(irc.distracted.net <-
for_ = next_arg(p, &p);
fr = next_arg(p, &p);
next_arg(p, &temp2);
serversay(from, "%s", convert_output_format(" Remote Connect of $1:$2 from $3", "%s %s %s %s", update_clock(GET_TIME), for_, fr, temp2));
serversay(from, "%s", convert_output_format("Remote Connect of $1:$2 from $3", "%s %s %s %s", update_clock(GET_TIME), for_, fr, temp2));
}
else if (!strncmp(line, "Client connecting", 17) || !strncmp(line, "Client exiting", 14))
{
@@ -561,7 +561,7 @@ irc.BitchX.com *** Notice -- Nick collision on nickserv(irc.distracted.net <-
if (!(flags & NICK_FLOODING))
goto done;
p = line + 26;
serversay(from, "%s", convert_output_format(" Nick Flooding %K[%B$1-%K]", "%s %s", update_clock(GET_TIME), for_));
serversay(from, "%s", convert_output_format("Nick Flooding %K[%B$1-%K]", "%s %s", update_clock(GET_TIME), for_));
}
else if (!strncmp(line, "Kill line active for", 20) || !strncmp(line+14, "K-line active for", 17))
{
@@ -572,7 +572,7 @@ irc.BitchX.com *** Notice -- Nick collision on nickserv(irc.distracted.net <-
for_ = line + 20;
else
for_ = line + 17;
serversay(from, "%s", convert_output_format(" Kill line for $1 active", "%s %s", update_clock(GET_TIME), for_));
serversay(from, "%s", convert_output_format("Kill line for $1 active", "%s %s", update_clock(GET_TIME), for_));
}
else
{