summaryrefslogtreecommitdiff
path: root/modules/protocol
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2012-02-18 15:04:26 -0500
committerAdam <Adam@anope.org>2012-02-18 15:04:26 -0500
commitee5cd8493e34a1c049066ead25e9094b30cd49b5 (patch)
tree846c6dcd9bb2c4d721c6290a9b9d6b6ed880acdb /modules/protocol
parent41e8d276023e8fefc22fb89c2f81ae17b8222155 (diff)
Use C++11's explicit override feature if available
Diffstat (limited to 'modules/protocol')
-rw-r--r--modules/protocol/bahamut.cpp64
-rw-r--r--modules/protocol/inspircd-ts6.h74
-rw-r--r--modules/protocol/inspircd11.cpp66
-rw-r--r--modules/protocol/inspircd12.cpp10
-rw-r--r--modules/protocol/inspircd20.cpp12
-rw-r--r--modules/protocol/plexus.cpp64
-rw-r--r--modules/protocol/ratbox.cpp60
-rw-r--r--modules/protocol/unreal.cpp84
8 files changed, 217 insertions, 217 deletions
diff --git a/modules/protocol/bahamut.cpp b/modules/protocol/bahamut.cpp
index b83afa686..8645c7176 100644
--- a/modules/protocol/bahamut.cpp
+++ b/modules/protocol/bahamut.cpp
@@ -44,7 +44,7 @@ IRCDVar myIrcd[] = {
class BahamutIRCdProto : public IRCDProto
{
- void SendModeInternal(const BotInfo *source, const Channel *dest, const Anope::string &buf)
+ void SendModeInternal(const BotInfo *source, const Channel *dest, const Anope::string &buf) anope_override
{
if (Capab.count("TSMODE") > 0)
UplinkSocket::Message(source ? source->nick : Config->ServerName) << "MODE " << dest->name << " " << dest->creation_time << " " << buf;
@@ -52,37 +52,37 @@ class BahamutIRCdProto : public IRCDProto
UplinkSocket::Message(source ? source->nick : Config->ServerName) << "MODE " << dest->name << " " << buf;
}
- void SendModeInternal(const BotInfo *bi, const User *u, const Anope::string &buf)
+ void SendModeInternal(const BotInfo *bi, const User *u, const Anope::string &buf) anope_override
{
UplinkSocket::Message(bi ? bi->nick : Config->ServerName) << "SVSMODE " << u->nick << " " << u->timestamp << " " << buf;
}
/* SVSHOLD - set */
- void SendSVSHold(const Anope::string &nick)
+ void SendSVSHold(const Anope::string &nick) anope_override
{
UplinkSocket::Message(Config->ServerName) << "SVSHOLD " << nick << " " << Config->NSReleaseTimeout << " :Being held for registered user";
}
/* SVSHOLD - release */
- void SendSVSHoldDel(const Anope::string &nick)
+ void SendSVSHoldDel(const Anope::string &nick) anope_override
{
UplinkSocket::Message(Config->ServerName) << "SVSHOLD " << nick << " 0";
}
/* SQLINE */
- void SendSQLine(User *, const XLine *x)
+ void SendSQLine(User *, const XLine *x) anope_override
{
UplinkSocket::Message() << "SQLINE " << x->Mask << " :" << x->Reason;
}
/* UNSLINE */
- void SendSGLineDel(const XLine *x)
+ void SendSGLineDel(const XLine *x) anope_override
{
UplinkSocket::Message() << "UNSGLINE 0 :" << x->Mask;
}
/* UNSZLINE */
- void SendSZLineDel(const XLine *x)
+ void SendSZLineDel(const XLine *x) anope_override
{
/* this will likely fail so its only here for legacy */
UplinkSocket::Message() << "UNSZLINE 0 " << x->GetHost();
@@ -91,7 +91,7 @@ class BahamutIRCdProto : public IRCDProto
}
/* SZLINE */
- void SendSZLine(User *, const XLine *x)
+ void SendSZLine(User *, const XLine *x) anope_override
{
// Calculate the time left before this would expire, capping it at 2 days
time_t timeleft = x->Expires - Anope::CurTime;
@@ -104,37 +104,37 @@ class BahamutIRCdProto : public IRCDProto
}
/* SVSNOOP */
- void SendSVSNOOP(const Server *server, bool set)
+ void SendSVSNOOP(const Server *server, bool set) anope_override
{
UplinkSocket::Message() << "SVSNOOP " << server->GetName() << " " << (set ? "+" : "-");
}
/* SGLINE */
- void SendSGLine(User *, const XLine *x)
+ void SendSGLine(User *, const XLine *x) anope_override
{
UplinkSocket::Message() << "SGLINE " << x->Mask.length() << " :" << x->Mask << ":" << x->Reason;
}
/* RAKILL */
- void SendAkillDel(const XLine *x)
+ void SendAkillDel(const XLine *x) anope_override
{
UplinkSocket::Message() << "RAKILL " << x->GetHost() << " " << x->GetUser();
}
/* TOPIC */
- void SendTopic(BotInfo *whosets, Channel *c)
+ void SendTopic(BotInfo *whosets, Channel *c) anope_override
{
UplinkSocket::Message(whosets->nick) << "TOPIC " << c->name << " " << c->topic_setter << " " << c->topic_time << " :" << c->topic;
}
/* UNSQLINE */
- void SendSQLineDel(const XLine *x)
+ void SendSQLineDel(const XLine *x) anope_override
{
UplinkSocket::Message() << "UNSQLINE " << x->Mask;
}
/* JOIN - SJOIN */
- void SendJoin(User *user, Channel *c, const ChannelStatus *status)
+ void SendJoin(User *user, Channel *c, const ChannelStatus *status) anope_override
{
UplinkSocket::Message(user->nick) << "SJOIN " << c->creation_time << " " << c->name;
if (status)
@@ -155,7 +155,7 @@ class BahamutIRCdProto : public IRCDProto
}
}
- void SendAkill(User *, const XLine *x)
+ void SendAkill(User *, const XLine *x) anope_override
{
// Calculate the time left before this would expire, capping it at 2 days
time_t timeleft = x->Expires - Anope::CurTime;
@@ -167,22 +167,22 @@ class BahamutIRCdProto : public IRCDProto
/*
Note: if the stamp is null 0, the below usage is correct of Bahamut
*/
- void SendSVSKillInternal(const BotInfo *source, const User *user, const Anope::string &buf)
+ void SendSVSKillInternal(const BotInfo *source, const User *user, const Anope::string &buf) anope_override
{
UplinkSocket::Message(source ? source->nick : "") << "SVSKILL " << user->nick << " :" << buf;
}
- void SendBOB()
+ void SendBOB() anope_override
{
UplinkSocket::Message() << "BURST";
}
- void SendEOB()
+ void SendEOB() anope_override
{
UplinkSocket::Message() << "BURST 0";
}
- void SendKickInternal(const BotInfo *source, const Channel *chan, const User *user, const Anope::string &buf)
+ void SendKickInternal(const BotInfo *source, const Channel *chan, const User *user, const Anope::string &buf) anope_override
{
if (!buf.empty())
UplinkSocket::Message(source->nick) << "KICK " << chan->name << " " << user->nick << " :" << buf;
@@ -190,19 +190,19 @@ class BahamutIRCdProto : public IRCDProto
UplinkSocket::Message(source->nick) << "KICK " << chan->name << " " << user->nick;
}
- void SendClientIntroduction(const User *u)
+ void SendClientIntroduction(const User *u) anope_override
{
Anope::string modes = "+" + u->GetModes();
UplinkSocket::Message() << "NICK " << u->nick << " 1 " << u->timestamp << " " << modes << " " << u->GetIdent() << " " << u->host << " " << u->server->GetName() << " 0 0 :" << u->realname;
}
/* SERVER */
- void SendServer(const Server *server)
+ void SendServer(const Server *server) anope_override
{
UplinkSocket::Message() << "SERVER " << server->GetName() << " " << server->GetHops() << " :" << server->GetDescription();
}
- void SendConnect()
+ void SendConnect() anope_override
{
UplinkSocket::Message() << "PASS " << Config->Uplinks[CurrentUplink]->password << " :TS";
UplinkSocket::Message() << "CAPAB SSJOIN NOQUIT BURST UNCONNECT NICKIP TSMODE TS3";
@@ -219,7 +219,7 @@ class BahamutIRCdProto : public IRCDProto
this->SendBOB();
}
- void SendChannel(Channel *c)
+ void SendChannel(Channel *c) anope_override
{
Anope::string modes = c->GetModes(true, true);
if (modes.empty())
@@ -227,13 +227,13 @@ class BahamutIRCdProto : public IRCDProto
UplinkSocket::Message() << "SJOIN " << c->creation_time << " " << c->name << " " << modes << " :";
}
- void SendLogin(User *u)
+ void SendLogin(User *u) anope_override
{
BotInfo *ns = findbot(Config->NickServ);
ircdproto->SendMode(ns, u, "+d %d", u->timestamp);
}
- void SendLogout(User *u)
+ void SendLogout(User *u) anope_override
{
BotInfo *ns = findbot(Config->NickServ);
ircdproto->SendMode(ns, u, "+d 1");
@@ -243,7 +243,7 @@ class BahamutIRCdProto : public IRCDProto
class BahamutIRCdMessage : public IRCdMessage
{
public:
- bool OnMode(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnMode(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
if (params.size() > 2 && (params[0][0] == '#' || params[0][0] == '&'))
do_cmode(source, params[0], params[2], params[1]);
@@ -271,7 +271,7 @@ class BahamutIRCdMessage : public IRCdMessage
** parv[0] = new nickname
** parv[1] = hopcount
*/
- bool OnNick(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnNick(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
if (params.size() != 2)
{
@@ -299,13 +299,13 @@ class BahamutIRCdMessage : public IRCdMessage
return true;
}
- bool OnServer(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnServer(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
do_server(source, params[0], Anope::string(params[1]).is_pos_number_only() ? convertTo<unsigned>(params[1]) : 0, params[2], "");
return true;
}
- bool OnTopic(const Anope::string &, const std::vector<Anope::string> &params)
+ bool OnTopic(const Anope::string &, const std::vector<Anope::string> &params) anope_override
{
if (params.size() < 4)
return true;
@@ -322,7 +322,7 @@ class BahamutIRCdMessage : public IRCdMessage
return true;
}
- bool OnSJoin(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnSJoin(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
Channel *c = findchan(params[1]);
time_t ts = Anope::string(params[0]).is_pos_number_only() ? convertTo<time_t>(params[0]) : 0;
@@ -480,7 +480,7 @@ class ChannelModeFlood : public ChannelModeParam
public:
ChannelModeFlood(char modeChar, bool minusNoArg) : ChannelModeParam(CMODE_FLOOD, modeChar, minusNoArg) { }
- bool IsValid(const Anope::string &value) const
+ bool IsValid(const Anope::string &value) const anope_override
{
try
{
@@ -560,7 +560,7 @@ class ProtoBahamut : public Module
pmodule_ircd_message(NULL);
}
- void OnUserNickChange(User *u, const Anope::string &)
+ void OnUserNickChange(User *u, const Anope::string &) anope_override
{
u->RemoveModeInternal(ModeManager::FindUserModeByName(UMODE_REGISTERED));
}
diff --git a/modules/protocol/inspircd-ts6.h b/modules/protocol/inspircd-ts6.h
index a13104d78..8ba879c4c 100644
--- a/modules/protocol/inspircd-ts6.h
+++ b/modules/protocol/inspircd-ts6.h
@@ -14,7 +14,7 @@ class ChannelModeFlood : public ChannelModeParam
public:
ChannelModeFlood(char modeChar, bool minusNoArg) : ChannelModeParam(CMODE_FLOOD, modeChar, minusNoArg) { }
- bool IsValid(const Anope::string &value) const
+ bool IsValid(const Anope::string &value) const anope_override
{
try
{
@@ -49,18 +49,18 @@ class InspIRCdTS6Proto : public IRCDProto
public:
- void SendAkillDel(const XLine *x)
+ void SendAkillDel(const XLine *x) anope_override
{
BotInfo *bi = findbot(Config->OperServ);
UplinkSocket::Message(bi ? bi->GetUID() : Config->Numeric) << "GLINE " << x->Mask;
}
- void SendTopic(BotInfo *whosets, Channel *c)
+ void SendTopic(BotInfo *whosets, Channel *c) anope_override
{
UplinkSocket::Message(whosets->GetUID()) << "FTOPIC " << c->name << " " << Anope::CurTime << " " << c->topic_setter << " :" << c->topic;
}
- void SendVhostDel(User *u)
+ void SendVhostDel(User *u) anope_override
{
if (u->HasMode(UMODE_CLOAK))
this->SendChgHostInternal(u->nick, u->chost);
@@ -71,7 +71,7 @@ class InspIRCdTS6Proto : public IRCDProto
this->SendChgIdentInternal(u->nick, u->GetIdent());
}
- void SendAkill(User *, const XLine *x)
+ void SendAkill(User *, const XLine *x) anope_override
{
// Calculate the time left before this would expire, capping it at 2 days
time_t timeleft = x->Expires - Anope::CurTime;
@@ -81,33 +81,33 @@ class InspIRCdTS6Proto : public IRCDProto
UplinkSocket::Message(u ? u->GetUID() : Config->Numeric) << "ADDLINE G " << x->GetUser() << "@" << x->GetHost() << " " << x->By << " " << Anope::CurTime << " " << timeleft << " :" << x->Reason;
}
- void SendSVSKillInternal(const BotInfo *source, const User *user, const Anope::string &buf)
+ void SendSVSKillInternal(const BotInfo *source, const User *user, const Anope::string &buf) anope_override
{
UplinkSocket::Message(source ? source->GetUID() : Config->Numeric) << "KILL " << user->GetUID() << " :" << buf;
}
- void SendNumericInternal(const Anope::string &source, int numeric, const Anope::string &dest, const Anope::string &buf)
+ void SendNumericInternal(const Anope::string &source, int numeric, const Anope::string &dest, const Anope::string &buf) anope_override
{
UplinkSocket::Message(Config->Numeric) << "PUSH " << dest << " ::" << source << " " << numeric << " " << dest << " " << buf;
}
- void SendModeInternal(const BotInfo *source, const Channel *dest, const Anope::string &buf)
+ void SendModeInternal(const BotInfo *source, const Channel *dest, const Anope::string &buf) anope_override
{
UplinkSocket::Message(source ? source->GetUID() : Config->Numeric) << "FMODE " << dest->name << " " << dest->creation_time << " " << buf;
}
- void SendModeInternal(const BotInfo *bi, const User *u, const Anope::string &buf)
+ void SendModeInternal(const BotInfo *bi, const User *u, const Anope::string &buf) anope_override
{
UplinkSocket::Message(bi ? bi->GetUID() : Config->Numeric) << "MODE " << u->GetUID() << " " << buf;
}
- void SendClientIntroduction(const User *u)
+ void SendClientIntroduction(const User *u) anope_override
{
Anope::string modes = "+" + u->GetModes();
UplinkSocket::Message(Config->Numeric) << "UID " << u->GetUID() << " " << u->timestamp << " " << u->nick << " " << u->host << " " << u->host << " " << u->GetIdent() << " 0.0.0.0 " << u->my_signon << " " << modes << " :" << u->realname;
}
- void SendKickInternal(const BotInfo *source, const Channel *chan, const User *user, const Anope::string &buf)
+ void SendKickInternal(const BotInfo *source, const Channel *chan, const User *user, const Anope::string &buf) anope_override
{
if (!buf.empty())
UplinkSocket::Message(source->GetUID()) << "KICK " << chan->name << " " << user->GetUID() << " :" << buf;
@@ -116,13 +116,13 @@ class InspIRCdTS6Proto : public IRCDProto
}
/* SERVER services-dev.chatspike.net password 0 :Description here */
- void SendServer(const Server *server)
+ void SendServer(const Server *server) anope_override
{
UplinkSocket::Message("") << "SERVER " << server->GetName() << " " << Config->Uplinks[CurrentUplink]->password << " " << server->GetHops() << " " << server->GetSID() << " :" << server->GetDescription();
}
/* JOIN */
- void SendJoin(User *user, Channel *c, const ChannelStatus *status)
+ void SendJoin(User *user, Channel *c, const ChannelStatus *status) anope_override
{
UplinkSocket::Message(Config->Numeric) << "FJOIN " << c->name << " " << c->creation_time << " +" << c->GetModes(true, true) << " :," << user->GetUID();
/* Note that we can send this with the FJOIN but choose not to
@@ -148,13 +148,13 @@ class InspIRCdTS6Proto : public IRCDProto
}
/* UNSQLINE */
- void SendSQLineDel(const XLine *x)
+ void SendSQLineDel(const XLine *x) anope_override
{
UplinkSocket::Message(Config->Numeric) << "DELLINE Q " << x->Mask;
}
/* SQLINE */
- void SendSQLine(User *, const XLine *x)
+ void SendSQLine(User *, const XLine *x) anope_override
{
// Calculate the time left before this would expire, capping it at 2 days
time_t timeleft = x->Expires - Anope::CurTime;
@@ -165,7 +165,7 @@ class InspIRCdTS6Proto : public IRCDProto
/* Functions that use serval cmd functions */
- void SendVhost(User *u, const Anope::string &vIdent, const Anope::string &vhost)
+ void SendVhost(User *u, const Anope::string &vIdent, const Anope::string &vhost) anope_override
{
if (!vIdent.empty())
this->SendChgIdentInternal(u->nick, vIdent);
@@ -173,7 +173,7 @@ class InspIRCdTS6Proto : public IRCDProto
this->SendChgHostInternal(u->nick, vhost);
}
- void SendConnect()
+ void SendConnect() anope_override
{
SendServer(Me);
UplinkSocket::Message(Config->Numeric) << "BURST";
@@ -182,7 +182,7 @@ class InspIRCdTS6Proto : public IRCDProto
}
/* SVSHOLD - set */
- void SendSVSHold(const Anope::string &nick)
+ void SendSVSHold(const Anope::string &nick) anope_override
{
BotInfo *bi = findbot(Config->NickServ);
if (bi)
@@ -190,7 +190,7 @@ class InspIRCdTS6Proto : public IRCDProto
}
/* SVSHOLD - release */
- void SendSVSHoldDel(const Anope::string &nick)
+ void SendSVSHoldDel(const Anope::string &nick) anope_override
{
BotInfo *bi = findbot(Config->NickServ);
if (bi)
@@ -198,13 +198,13 @@ class InspIRCdTS6Proto : public IRCDProto
}
/* UNSZLINE */
- void SendSZLineDel(const XLine *x)
+ void SendSZLineDel(const XLine *x) anope_override
{
UplinkSocket::Message(Config->Numeric) << "DELLINE Z " << x->GetHost();
}
/* SZLINE */
- void SendSZLine(User *, const XLine *x)
+ void SendSZLine(User *, const XLine *x) anope_override
{
// Calculate the time left before this would expire, capping it at 2 days
time_t timeleft = x->Expires - Anope::CurTime;
@@ -213,26 +213,26 @@ class InspIRCdTS6Proto : public IRCDProto
UplinkSocket::Message(Config->Numeric) << "ADDLINE Z " << x->GetHost() << " " << x->By << " " << Anope::CurTime << " " << timeleft <<" :" << x->Reason;
}
- void SendSVSJoin(const Anope::string &source, const Anope::string &nick, const Anope::string &chan, const Anope::string &)
+ void SendSVSJoin(const Anope::string &source, const Anope::string &nick, const Anope::string &chan, const Anope::string &) anope_override
{
User *u = finduser(nick);
BotInfo *bi = findbot(source);
UplinkSocket::Message(bi->GetUID()) << "SVSJOIN " << u->GetUID() << " " << chan;
}
- void SendSWhois(const Anope::string &, const Anope::string &who, const Anope::string &mask)
+ void SendSWhois(const Anope::string &, const Anope::string &who, const Anope::string &mask) anope_override
{
User *u = finduser(who);
UplinkSocket::Message(Config->Numeric) << "METADATA " << u->GetUID() << " swhois :" << mask;
}
- void SendBOB()
+ void SendBOB() anope_override
{
UplinkSocket::Message(Config->Numeric) << "BURST " << Anope::CurTime;
}
- void SendEOB()
+ void SendEOB() anope_override
{
UplinkSocket::Message(Config->Numeric) << "ENDBURST";
}
@@ -245,7 +245,7 @@ class InspIRCdTS6Proto : public IRCDProto
UplinkSocket::Message(source ? source->GetUID() : Config->Numeric) << "SNONOTICE A :" << buf;
}
- void SendLogin(User *u)
+ void SendLogin(User *u) anope_override
{
if (!u->Account() || u->Account()->HasFlag(NI_UNCONFIRMED))
return;
@@ -253,17 +253,17 @@ class InspIRCdTS6Proto : public IRCDProto
UplinkSocket::Message(Config->Numeric) << "METADATA " << u->GetUID() << " accountname :" << u->Account()->display;
}
- void SendLogout(User *u)
+ void SendLogout(User *u) anope_override
{
UplinkSocket::Message(Config->Numeric) << "METADATA " << u->GetUID() << " accountname :";
}
- void SendChannel(Channel *c)
+ void SendChannel(Channel *c) anope_override
{
UplinkSocket::Message(Config->Numeric) << "FJOIN " << c->name << " " << c->creation_time << " +" << c->GetModes(true, true) << " :";
}
- bool IsNickValid(const Anope::string &nick)
+ bool IsNickValid(const Anope::string &nick) anope_override
{
/* InspIRCd, like TS6, uses UIDs on collision, so... */
if (isdigit(nick[0]))
@@ -276,7 +276,7 @@ class InspIRCdTS6Proto : public IRCDProto
class InspircdIRCdMessage : public IRCdMessage
{
public:
- bool OnMode(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnMode(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
if (params[0][0] == '#' || params[0][0] == '&')
do_cmode(source, params[0], params[2], params[1]);
@@ -301,15 +301,15 @@ class InspircdIRCdMessage : public IRCdMessage
return true;
}
- virtual bool OnUID(const Anope::string &source, const std::vector<Anope::string> &params) = 0;
+ virtual bool OnUID(const Anope::string &source, const std::vector<Anope::string> &params) anope_override = 0;
- bool OnNick(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnNick(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
do_nick(source, params[0], "", "", "", "", 0, "", "", "", "");
return true;
}
- bool OnPrivmsg(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnPrivmsg(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
/* Ignore privmsgs from the server, which can happen. */
if (Server::Find(source) != NULL)
@@ -326,13 +326,13 @@ class InspircdIRCdMessage : public IRCdMessage
* 3: numeric
* 4: desc
*/
- bool OnServer(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnServer(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
do_server(source, params[0], Anope::string(params[2]).is_pos_number_only() ? convertTo<unsigned>(params[2]) : 0, params[4], params[3]);
return true;
}
- bool OnTopic(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnTopic(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
Channel *c = findchan(params[0]);
@@ -347,9 +347,9 @@ class InspircdIRCdMessage : public IRCdMessage
return true;
}
- virtual bool OnCapab(const Anope::string &, const std::vector<Anope::string> &) = 0;
+ virtual bool OnCapab(const Anope::string &, const std::vector<Anope::string> &) anope_override = 0;
- bool OnSJoin(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnSJoin(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
Channel *c = findchan(params[0]);
time_t ts = Anope::string(params[1]).is_pos_number_only() ? convertTo<time_t>(params[1]) : 0;
diff --git a/modules/protocol/inspircd11.cpp b/modules/protocol/inspircd11.cpp
index d984e597e..49a90f831 100644
--- a/modules/protocol/inspircd11.cpp
+++ b/modules/protocol/inspircd11.cpp
@@ -82,17 +82,17 @@ void inspircd_cmd_pass(const Anope::string &pass)
class InspIRCdProto : public IRCDProto
{
- void SendAkillDel(const XLine *x)
+ void SendAkillDel(const XLine *x) anope_override
{
UplinkSocket::Message(Config->OperServ) << "GLINE " << x->Mask;
}
- void SendTopic(BotInfo *whosets, Channel *c)
+ void SendTopic(BotInfo *whosets, Channel *c) anope_override
{
UplinkSocket::Message(whosets->nick) << "FTOPIC " << c->name << " " << c->topic_time << " " << c->topic_setter <<" :" << c->topic;
}
- void SendVhostDel(User *u)
+ void SendVhostDel(User *u) anope_override
{
if (u->HasMode(UMODE_CLOAK))
inspircd_cmd_chghost(u->nick, u->chost);
@@ -103,7 +103,7 @@ class InspIRCdProto : public IRCDProto
inspircd_cmd_chgident(u->nick, u->GetIdent());
}
- void SendAkill(User *, const XLine *x)
+ void SendAkill(User *, const XLine *x) anope_override
{
// Calculate the time left before this would expire, capping it at 2 days
time_t timeleft = x->Expires - Anope::CurTime;
@@ -112,34 +112,34 @@ class InspIRCdProto : public IRCDProto
UplinkSocket::Message(Config->ServerName) << "ADDLINE G " << x->Mask << " " << x->By << " " << Anope::CurTime << " " << timeleft << " :" << x->Reason;
}
- void SendSVSKillInternal(const BotInfo *source, const User *user, const Anope::string &buf)
+ void SendSVSKillInternal(const BotInfo *source, const User *user, const Anope::string &buf) anope_override
{
UplinkSocket::Message(source ? source->nick : Config->ServerName) << "KILL " << user->nick << " :" << buf;
}
- void SendNumericInternal(const Anope::string &source, int numeric, const Anope::string &dest, const Anope::string &buf)
+ void SendNumericInternal(const Anope::string &source, int numeric, const Anope::string &dest, const Anope::string &buf) anope_override
{
UplinkSocket::Message(source) << "PUSH " << dest << " ::" << source << " " << numeric << " " << dest << " " << buf;
}
- void SendModeInternal(const BotInfo *source, const Channel *dest, const Anope::string &buf)
+ void SendModeInternal(const BotInfo *source, const Channel *dest, const Anope::string &buf) anope_override
{
UplinkSocket::Message(source ? source->nick : Config->ServerName) << "FMODE " << dest->name << " " << dest->creation_time << " " << buf;
}
- void SendModeInternal(const BotInfo *bi, const User *u, const Anope::string &buf)
+ void SendModeInternal(const BotInfo *bi, const User *u, const Anope::string &buf) anope_override
{
UplinkSocket::Message(bi ? bi->nick : Config->ServerName) << "MODE " << u->nick << " " << buf;
}
- void SendClientIntroduction(const User *u)
+ void SendClientIntroduction(const User *u) anope_override
{
Anope::string modes = "+" + u->GetModes();
UplinkSocket::Message(Config->ServerName) << "NICK " << u->timestamp << " " << u->nick << " " << u->host << " " << u->host << " " << u->GetIdent() << " " << modes << " 0.0.0.0 :" << u->realname;
UplinkSocket::Message(u->nick) << "OPERTYPE Service";
}
- void SendKickInternal(const BotInfo *source, const Channel *chan, const User *user, const Anope::string &buf)
+ void SendKickInternal(const BotInfo *source, const Channel *chan, const User *user, const Anope::string &buf) anope_override
{
if (!buf.empty())
UplinkSocket::Message(source->nick) << "KICK " << chan->name << " " << user->nick << " :" << buf;
@@ -148,13 +148,13 @@ class InspIRCdProto : public IRCDProto
}
/* SERVER services-dev.chatspike.net password 0 :Description here */
- void SendServer(const Server *server)
+ void SendServer(const Server *server) anope_override
{
UplinkSocket::Message(Config->ServerName) << "SERVER " << server->GetName() << " " << currentpass << " " << server->GetHops() << " :" << server->GetDescription();
}
/* JOIN */
- void SendJoin(User *user, Channel *c, const ChannelStatus *status)
+ void SendJoin(User *user, Channel *c, const ChannelStatus *status) anope_override
{
UplinkSocket::Message(user->nick) << "JOIN " << c->name << " " << c->creation_time;
if (status)
@@ -176,13 +176,13 @@ class InspIRCdProto : public IRCDProto
}
/* UNSQLINE */
- void SendSQLineDel(const XLine *x)
+ void SendSQLineDel(const XLine *x) anope_override
{
UplinkSocket::Message(Config->OperServ) << "QLINE " << x->Mask;
}
/* SQLINE */
- void SendSQLine(User *, const XLine *x)
+ void SendSQLine(User *, const XLine *x) anope_override
{
// Calculate the time left before this would expire, capping it at 2 days
time_t timeleft = x->Expires - Anope::CurTime;
@@ -193,7 +193,7 @@ class InspIRCdProto : public IRCDProto
/* Functions that use serval cmd functions */
- void SendVhost(User *u, const Anope::string &vIdent, const Anope::string &vhost)
+ void SendVhost(User *u, const Anope::string &vIdent, const Anope::string &vhost) anope_override
{
if (!vIdent.empty())
inspircd_cmd_chgident(u->nick, vIdent);
@@ -201,7 +201,7 @@ class InspIRCdProto : public IRCDProto
inspircd_cmd_chghost(u->nick, vhost);
}
- void SendConnect()
+ void SendConnect() anope_override
{
inspircd_cmd_pass(Config->Uplinks[CurrentUplink]->password);
SendServer(Me);
@@ -224,25 +224,25 @@ class InspIRCdProto : public IRCDProto
}
/* SVSHOLD - set */
- void SendSVSHold(const Anope::string &nick)
+ void SendSVSHold(const Anope::string &nick) anope_override
{
UplinkSocket::Message(Config->OperServ) << "SVSHOLD " << nick << " " << Config->NSReleaseTimeout << "s :Being held for registered user";
}
/* SVSHOLD - release */
- void SendSVSHoldDel(const Anope::string &nick)
+ void SendSVSHoldDel(const Anope::string &nick) anope_override
{
UplinkSocket::Message(Config->OperServ) << "SVSHOLD " << nick;
}
/* UNSZLINE */
- void SendSZLineDel(const XLine *x)
+ void SendSZLineDel(const XLine *x) anope_override
{
UplinkSocket::Message(Config->OperServ) << "ZLINE " << x->GetHost();
}
/* SZLINE */
- void SendSZLine(User *, const XLine *x)
+ void SendSZLine(User *, const XLine *x) anope_override
{
// Calculate the time left before this would expire, capping it at 2 days
time_t timeleft = x->Expires - Anope::CurTime;
@@ -251,22 +251,22 @@ class InspIRCdProto : public IRCDProto
UplinkSocket::Message(Config->ServerName) << "ADDLINE Z " << x->GetHost() << " " << x->By << " " << Anope::CurTime << " " << timeleft << " :" << x->Reason;
}
- void SendSVSJoin(const Anope::string &source, const Anope::string &nick, const Anope::string &chan, const Anope::string &)
+ void SendSVSJoin(const Anope::string &source, const Anope::string &nick, const Anope::string &chan, const Anope::string &) anope_override
{
UplinkSocket::Message(source) << "SVSJOIN " << nick << " " << chan;
}
- void SendBOB()
+ void SendBOB() anope_override
{
UplinkSocket::Message() << "BURST " << Anope::CurTime;
}
- void SendEOB()
+ void SendEOB() anope_override
{
UplinkSocket::Message() << "ENDBURST";
}
- void SendLogin(User *u)
+ void SendLogin(User *u) anope_override
{
if (!u->Account())
return;
@@ -275,7 +275,7 @@ class InspIRCdProto : public IRCDProto
u->Account()->Extend("authenticationtoken", new ExtensibleString(svidbuf));
}
- void SendLogout(User *u)
+ void SendLogout(User *u) anope_override
{
}
};
@@ -285,7 +285,7 @@ class ChannelModeFlood : public ChannelModeParam
public:
ChannelModeFlood(char modeChar, bool minusNoArg) : ChannelModeParam(CMODE_FLOOD, modeChar, minusNoArg) { }
- bool IsValid(const Anope::string &value) const
+ bool IsValid(const Anope::string &value) const anope_override
{
try
{
@@ -302,7 +302,7 @@ class ChannelModeFlood : public ChannelModeParam
class InspircdIRCdMessage : public IRCdMessage
{
public:
- bool OnMode(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnMode(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
if (params.size() < 2)
return true;
@@ -315,7 +315,7 @@ class InspircdIRCdMessage : public IRCdMessage
return true;
}
- bool OnNick(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnNick(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
if (params.size() == 8)
{
@@ -343,13 +343,13 @@ class InspircdIRCdMessage : public IRCdMessage
return true;
}
- bool OnServer(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnServer(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
do_server(source, params[0], Anope::string(params[1]).is_pos_number_only() ? convertTo<unsigned>(params[1]) : 0, params[2], "");
return true;
}
- bool OnTopic(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnTopic(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
Channel *c = findchan(params[0]);
@@ -364,7 +364,7 @@ class InspircdIRCdMessage : public IRCdMessage
return true;
}
- bool OnCapab(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnCapab(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
if (params[0].equals_cs("START"))
{
@@ -598,7 +598,7 @@ class InspircdIRCdMessage : public IRCdMessage
return true;
}
- bool OnSJoin(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnSJoin(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
Channel *c = findchan(params[0]);
time_t ts = Anope::string(params[1]).is_pos_number_only() ? convertTo<time_t>(params[1]) : 0;
@@ -925,7 +925,7 @@ class ProtoInspIRCd : public Module
ModuleManager::Attach(I_OnUserNickChange, this);
}
- void OnUserNickChange(User *u, const Anope::string &)
+ void OnUserNickChange(User *u, const Anope::string &) anope_override
{
u->RemoveModeInternal(ModeManager::FindUserModeByName(UMODE_REGISTERED));
}
diff --git a/modules/protocol/inspircd12.cpp b/modules/protocol/inspircd12.cpp
index 8fd29c7e8..e2ec39ebe 100644
--- a/modules/protocol/inspircd12.cpp
+++ b/modules/protocol/inspircd12.cpp
@@ -268,7 +268,7 @@ class InspIRCdExtBan : public ChannelModeList
public:
InspIRCdExtBan(ChannelModeName mName, char modeChar) : ChannelModeList(mName, modeChar) { }
- bool Matches(User *u, const Entry *e)
+ bool Matches(User *u, const Entry *e) anope_override
{
const Anope::string &mask = e->mask;
@@ -330,7 +330,7 @@ class Inspircd12IRCdMessage : public InspircdIRCdMessage
* 8+: modes and params -- IMPORTANT, some modes (e.g. +s) may have parameters. So don't assume a fixed position of realname!
* last: realname
*/
- bool OnUID(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnUID(const Anope::string &source, const std::vector<Anope::string> &params) anope_override
{
time_t ts = convertTo<time_t>(params[1]);
@@ -344,7 +344,7 @@ class Inspircd12IRCdMessage : public InspircdIRCdMessage
return true;
}
- bool OnCapab(const Anope::string &source, const std::vector<Anope::string> &params)
+ bool OnCa