diff options
| author | 2019-01-25 02:52:11 +0000 | |
|---|---|---|
| committer | 2019-01-25 02:52:11 +0000 | |
| commit | c78ecdf579c0bf0a75ed0f9641ffef8d89c17ec8 (patch) | |
| tree | 4d7b4e6135e4b8340698419a83bc29edec18a5ea /src/modules/extra | |
| parent | Remove the DEPRECATED_METHOD macro. (diff) | |
| download | inspircd++-c78ecdf579c0bf0a75ed0f9641ffef8d89c17ec8.tar.gz inspircd++-c78ecdf579c0bf0a75ed0f9641ffef8d89c17ec8.tar.bz2 inspircd++-c78ecdf579c0bf0a75ed0f9641ffef8d89c17ec8.zip | |
Replace the override macro with the override keyword.
Diffstat (limited to 'src/modules/extra')
| -rw-r--r-- | src/modules/extra/m_geoip.cpp | 18 | ||||
| -rw-r--r-- | src/modules/extra/m_ldap.cpp | 36 | ||||
| -rw-r--r-- | src/modules/extra/m_mysql.cpp | 26 | ||||
| -rw-r--r-- | src/modules/extra/m_pgsql.cpp | 30 | ||||
| -rw-r--r-- | src/modules/extra/m_regex_pcre.cpp | 6 | ||||
| -rw-r--r-- | src/modules/extra/m_regex_posix.cpp | 8 | ||||
| -rw-r--r-- | src/modules/extra/m_regex_re2.cpp | 6 | ||||
| -rw-r--r-- | src/modules/extra/m_regex_stdlib.cpp | 8 | ||||
| -rw-r--r-- | src/modules/extra/m_regex_tre.cpp | 6 | ||||
| -rw-r--r-- | src/modules/extra/m_sqlite3.cpp | 18 | ||||
| -rw-r--r-- | src/modules/extra/m_ssl_gnutls.cpp | 24 | ||||
| -rw-r--r-- | src/modules/extra/m_ssl_mbedtls.cpp | 24 | ||||
| -rw-r--r-- | src/modules/extra/m_ssl_openssl.cpp | 24 |
13 files changed, 117 insertions, 117 deletions
diff --git a/src/modules/extra/m_geoip.cpp b/src/modules/extra/m_geoip.cpp index e4299a1c2..7e2c1d43d 100644 --- a/src/modules/extra/m_geoip.cpp +++ b/src/modules/extra/m_geoip.cpp @@ -89,7 +89,7 @@ class ModuleGeoIP : public Module, public Stats::EventListener, public Whois::Ev { } - void init() CXX11_OVERRIDE + void init() override { ipv4db = GeoIP_open_type(GEOIP_COUNTRY_EDITION, GEOIP_STANDARD); if (!ipv4db) @@ -119,24 +119,24 @@ class ModuleGeoIP : public Module, public Stats::EventListener, public Whois::Ev GeoIP_delete(ipv6db); } - void ReadConfig(ConfigStatus&) CXX11_OVERRIDE + void ReadConfig(ConfigStatus&) override { ConfigTag* tag = ServerInstance->Config->ConfValue("geoip"); extban = tag->getBool("extban"); } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("Provides a way to assign users to connect classes by country using GeoIP lookup", VF_OPTCOMMON|VF_VENDOR); } - void On005Numeric(std::map<std::string, std::string>& tokens) CXX11_OVERRIDE + void On005Numeric(std::map<std::string, std::string>& tokens) override { if (extban) tokens["EXTBAN"].push_back('G'); } - ModResult OnCheckBan(User* user, Channel*, const std::string& mask) CXX11_OVERRIDE + ModResult OnCheckBan(User* user, Channel*, const std::string& mask) override { if (extban && (mask.length() > 2) && (mask[0] == 'G') && (mask[1] == ':')) { @@ -150,7 +150,7 @@ class ModuleGeoIP : public Module, public Stats::EventListener, public Whois::Ev return MOD_RES_PASSTHRU; } - ModResult OnSetConnectClass(LocalUser* user, ConnectClass* myclass) CXX11_OVERRIDE + ModResult OnSetConnectClass(LocalUser* user, ConnectClass* myclass) override { std::string* cc = ext.get(user); if (!cc) @@ -167,14 +167,14 @@ class ModuleGeoIP : public Module, public Stats::EventListener, public Whois::Ev return MOD_RES_DENY; } - void OnSetUserIP(LocalUser* user) CXX11_OVERRIDE + void OnSetUserIP(LocalUser* user) override { // If user has sent NICK/USER, re-set the ExtItem as this is likely CGI:IRC changing the IP if (user->registered == REG_NICKUSER) SetExt(user); } - void OnWhois(Whois::Context& whois) CXX11_OVERRIDE + void OnWhois(Whois::Context& whois) override { // If the extban is disabled we don't expose users location. if (!extban) @@ -187,7 +187,7 @@ class ModuleGeoIP : public Module, public Stats::EventListener, public Whois::Ev whois.SendLine(RPL_WHOISCOUNTRY, *cc, "is located in this country"); } - ModResult OnStats(Stats::Context& stats) CXX11_OVERRIDE + ModResult OnStats(Stats::Context& stats) override { if (stats.GetSymbol() != 'G') return MOD_RES_PASSTHRU; diff --git a/src/modules/extra/m_ldap.cpp b/src/modules/extra/m_ldap.cpp index 8c2752dbf..e2c5fd1c5 100644 --- a/src/modules/extra/m_ldap.cpp +++ b/src/modules/extra/m_ldap.cpp @@ -84,7 +84,7 @@ class LDAPBind : public LDAPRequest type = QUERY_BIND; } - int run() CXX11_OVERRIDE; + int run() override; }; class LDAPSearch : public LDAPRequest @@ -103,7 +103,7 @@ class LDAPSearch : public LDAPRequest type = QUERY_SEARCH; } - int run() CXX11_OVERRIDE; + int run() override; }; class LDAPAdd : public LDAPRequest @@ -120,7 +120,7 @@ class LDAPAdd : public LDAPRequest type = QUERY_ADD; } - int run() CXX11_OVERRIDE; + int run() override; }; class LDAPDel : public LDAPRequest @@ -135,7 +135,7 @@ class LDAPDel : public LDAPRequest type = QUERY_DELETE; } - int run() CXX11_OVERRIDE; + int run() override; }; class LDAPModify : public LDAPRequest @@ -152,7 +152,7 @@ class LDAPModify : public LDAPRequest type = QUERY_MODIFY; } - int run() CXX11_OVERRIDE; + int run() override; }; class LDAPCompare : public LDAPRequest @@ -169,7 +169,7 @@ class LDAPCompare : public LDAPRequest type = QUERY_COMPARE; } - int run() CXX11_OVERRIDE; + int run() override; }; class LDAPService : public LDAPProvider, public SocketThread @@ -330,20 +330,20 @@ class LDAPService : public LDAPProvider, public SocketThread } } - void BindAsManager(LDAPInterface* i) CXX11_OVERRIDE + void BindAsManager(LDAPInterface* i) override { std::string binddn = config->getString("binddn"); std::string bindauth = config->getString("bindauth"); this->Bind(i, binddn, bindauth); } - void Bind(LDAPInterface* i, const std::string& who, const std::string& pass) CXX11_OVERRIDE + void Bind(LDAPInterface* i, const std::string& who, const std::string& pass) override { LDAPBind* b = new LDAPBind(this, i, who, pass); QueueRequest(b); } - void Search(LDAPInterface* i, const std::string& base, const std::string& filter) CXX11_OVERRIDE + void Search(LDAPInterface* i, const std::string& base, const std::string& filter) override { if (i == NULL) throw LDAPException("No interface"); @@ -352,25 +352,25 @@ class LDAPService : public LDAPProvider, public SocketThread QueueRequest(s); } - void Add(LDAPInterface* i, const std::string& dn, LDAPMods& attributes) CXX11_OVERRIDE + void Add(LDAPInterface* i, const std::string& dn, LDAPMods& attributes) override { LDAPAdd* add = new LDAPAdd(this, i, dn, attributes); QueueRequest(add); } - void Del(LDAPInterface* i, const std::string& dn) CXX11_OVERRIDE + void Del(LDAPInterface* i, const std::string& dn) override { LDAPDel* del = new LDAPDel(this, i, dn); QueueRequest(del); } - void Modify(LDAPInterface* i, const std::string& base, LDAPMods& attributes) CXX11_OVERRIDE + void Modify(LDAPInterface* i, const std::string& base, LDAPMods& attributes) override { LDAPModify* mod = new LDAPModify(this, i, base, attributes); QueueRequest(mod); } - void Compare(LDAPInterface* i, const std::string& dn, const std::string& attr, const std::string& val) CXX11_OVERRIDE + void Compare(LDAPInterface* i, const std::string& dn, const std::string& attr, const std::string& val) override { LDAPCompare* comp = new LDAPCompare(this, i, dn, attr, val); QueueRequest(comp); @@ -476,7 +476,7 @@ class LDAPService : public LDAPProvider, public SocketThread } public: - void Run() CXX11_OVERRIDE + void Run() override { while (!this->GetExitFlag()) { @@ -489,7 +489,7 @@ class LDAPService : public LDAPProvider, public SocketThread } } - void OnNotify() CXX11_OVERRIDE + void OnNotify() override { query_queue r; @@ -524,7 +524,7 @@ class ModuleLDAP : public Module ServiceMap LDAPServices; public: - void ReadConfig(ConfigStatus& status) CXX11_OVERRIDE + void ReadConfig(ConfigStatus& status) override { ServiceMap conns; @@ -566,7 +566,7 @@ class ModuleLDAP : public Module LDAPServices.swap(conns); } - void OnUnloadModule(Module* m) CXX11_OVERRIDE + void OnUnloadModule(Module* m) override { for (ServiceMap::iterator it = this->LDAPServices.begin(); it != this->LDAPServices.end(); ++it) { @@ -615,7 +615,7 @@ class ModuleLDAP : public Module } } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("LDAP support", VF_VENDOR); } diff --git a/src/modules/extra/m_mysql.cpp b/src/modules/extra/m_mysql.cpp index 7c6729603..c1f7bde34 100644 --- a/src/modules/extra/m_mysql.cpp +++ b/src/modules/extra/m_mysql.cpp @@ -112,11 +112,11 @@ class ModuleSQL : public Module ConnMap connections; // main thread only ModuleSQL(); - void init() CXX11_OVERRIDE; + void init() override; ~ModuleSQL(); - void ReadConfig(ConfigStatus& status) CXX11_OVERRIDE; - void OnUnloadModule(Module* mod) CXX11_OVERRIDE; - Version GetVersion() CXX11_OVERRIDE; + void ReadConfig(ConfigStatus& status) override; + void OnUnloadModule(Module* mod) override; + Version GetVersion() override; }; class DispatcherThread : public SocketThread @@ -126,8 +126,8 @@ class DispatcherThread : public SocketThread public: DispatcherThread(ModuleSQL* CreatorModule) : Parent(CreatorModule) { } ~DispatcherThread() { } - void Run() CXX11_OVERRIDE; - void OnNotify() CXX11_OVERRIDE; + void Run() override; + void OnNotify() override; }; #if !defined(MYSQL_VERSION_ID) || MYSQL_VERSION_ID<32224 @@ -193,17 +193,17 @@ class MySQLresult : public SQL::Result } - int Rows() CXX11_OVERRIDE + int Rows() override { return rows; } - void GetCols(std::vector<std::string>& result) CXX11_OVERRIDE + void GetCols(std::vector<std::string>& result) override { result.assign(colnames.begin(), colnames.end()); } - bool HasColumn(const std::string& column, size_t& index) CXX11_OVERRIDE + bool HasColumn(const std::string& column, size_t& index) override { for (size_t i = 0; i < colnames.size(); ++i) { @@ -225,7 +225,7 @@ class MySQLresult : public SQL::Result return SQL::Field(); } - bool GetRow(SQL::Row& result) CXX11_OVERRIDE + bool GetRow(SQL::Row& result) override { if (currentrow < rows) { @@ -332,14 +332,14 @@ class SQLConnection : public SQL::Provider mysql_close(connection); } - void Submit(SQL::Query* q, const std::string& qs) CXX11_OVERRIDE + void Submit(SQL::Query* q, const std::string& qs) override { Parent()->Dispatcher->LockQueue(); Parent()->qq.push_back(QQueueItem(q, qs, this)); Parent()->Dispatcher->UnlockQueueWakeup(); } - void Submit(SQL::Query* call, const std::string& q, const SQL::ParamList& p) CXX11_OVERRIDE + void Submit(SQL::Query* call, const std::string& q, const SQL::ParamList& p) override { std::string res; unsigned int param = 0; @@ -366,7 +366,7 @@ class SQLConnection : public SQL::Provider Submit(call, res); } - void Submit(SQL::Query* call, const std::string& q, const SQL::ParamMap& p) CXX11_OVERRIDE + void Submit(SQL::Query* call, const std::string& q, const SQL::ParamMap& p) override { std::string res; for(std::string::size_type i = 0; i < q.length(); i++) diff --git a/src/modules/extra/m_pgsql.cpp b/src/modules/extra/m_pgsql.cpp index bb727b623..32bbd4459 100644 --- a/src/modules/extra/m_pgsql.cpp +++ b/src/modules/extra/m_pgsql.cpp @@ -65,7 +65,7 @@ class ReconnectTimer : public Timer ReconnectTimer(ModulePgSQL* m) : Timer(5, false), mod(m) { } - bool Tick(time_t TIME) CXX11_OVERRIDE; + bool Tick(time_t TIME) override; }; struct QueueItem @@ -110,19 +110,19 @@ class PgSQLresult : public SQL::Result PQclear(res); } - int Rows() CXX11_OVERRIDE + int Rows() override { return rows; } - void GetCols(std::vector<std::string>& result) CXX11_OVERRIDE + void GetCols(std::vector<std::string>& result) override { if (colnames.empty()) getColNames(); result = colnames; } - bool HasColumn(const std::string& column, size_t& index) CXX11_OVERRIDE + bool HasColumn(const std::string& column, size_t& index) override { if (colnames.empty()) getColNames(); @@ -147,7 +147,7 @@ class PgSQLresult : public SQL::Result return SQL::Field(std::string(v, PQgetlength(res, row, column))); } - bool GetRow(SQL::Row& result) CXX11_OVERRIDE + bool GetRow(SQL::Row& result) override { if (currentrow >= PQntuples(res)) return false; @@ -184,7 +184,7 @@ class SQLConn : public SQL::Provider, public EventHandler } } - CullResult cull() CXX11_OVERRIDE + CullResult cull() override { this->SQL::Provider::cull(); ServerInstance->Modules->DelService(*this); @@ -207,17 +207,17 @@ class SQLConn : public SQL::Provider, public EventHandler } } - void OnEventHandlerRead() CXX11_OVERRIDE + void OnEventHandlerRead() override { DoEvent(); } - void OnEventHandlerWrite() CXX11_OVERRIDE + void OnEventHandlerWrite() override { DoEvent(); } - void OnEventHandlerError(int errornum) CXX11_OVERRIDE + void OnEventHandlerError(int errornum) override { DelayReconnect(); } @@ -414,7 +414,7 @@ restart: } } - void Submit(SQL::Query *req, const std::string& q) CXX11_OVERRIDE + void Submit(SQL::Query *req, const std::string& q) override { if (qinprog.q.empty()) { @@ -427,7 +427,7 @@ restart: } } - void Submit(SQL::Query *req, const std::string& q, const SQL::ParamList& p) CXX11_OVERRIDE + void Submit(SQL::Query *req, const std::string& q, const SQL::ParamList& p) override { std::string res; unsigned int param = 0; @@ -452,7 +452,7 @@ restart: Submit(req, res); } - void Submit(SQL::Query *req, const std::string& q, const SQL::ParamMap& p) CXX11_OVERRIDE + void Submit(SQL::Query *req, const std::string& q, const SQL::ParamMap& p) override { std::string res; for(std::string::size_type i = 0; i < q.length(); i++) @@ -535,7 +535,7 @@ class ModulePgSQL : public Module ClearAllConnections(); } - void ReadConfig(ConfigStatus& status) CXX11_OVERRIDE + void ReadConfig(ConfigStatus& status) override { ReadConf(); } @@ -576,7 +576,7 @@ class ModulePgSQL : public Module connections.clear(); } - void OnUnloadModule(Module* mod) CXX11_OVERRIDE + void OnUnloadModule(Module* mod) override { SQL::Error err(SQL::BAD_DBID); for(ConnMap::iterator i = connections.begin(); i != connections.end(); i++) @@ -604,7 +604,7 @@ class ModulePgSQL : public Module } } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("PostgreSQL Service Provider module for all other m_sql* modules, uses v2 of the SQL API", VF_VENDOR); } diff --git a/src/modules/extra/m_regex_pcre.cpp b/src/modules/extra/m_regex_pcre.cpp index e8ef96c22..7896d3e05 100644 --- a/src/modules/extra/m_regex_pcre.cpp +++ b/src/modules/extra/m_regex_pcre.cpp @@ -56,7 +56,7 @@ class PCRERegex : public Regex pcre_free(regex); } - bool Matches(const std::string& text) CXX11_OVERRIDE + bool Matches(const std::string& text) override { return (pcre_exec(regex, NULL, text.c_str(), text.length(), 0, 0, NULL, 0) >= 0); } @@ -66,7 +66,7 @@ class PCREFactory : public RegexFactory { public: PCREFactory(Module* m) : RegexFactory(m, "regex/pcre") {} - Regex* Create(const std::string& expr) CXX11_OVERRIDE + Regex* Create(const std::string& expr) override { return new PCRERegex(expr); } @@ -80,7 +80,7 @@ class ModuleRegexPCRE : public Module { } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("Regex Provider Module for PCRE", VF_VENDOR); } diff --git a/src/modules/extra/m_regex_posix.cpp b/src/modules/extra/m_regex_posix.cpp index b5fddfab8..7b8e37e6a 100644 --- a/src/modules/extra/m_regex_posix.cpp +++ b/src/modules/extra/m_regex_posix.cpp @@ -54,7 +54,7 @@ class POSIXRegex : public Regex regfree(®buf); } - bool Matches(const std::string& text) CXX11_OVERRIDE + bool Matches(const std::string& text) override { return (regexec(®buf, text.c_str(), 0, NULL, 0) == 0); } @@ -65,7 +65,7 @@ class PosixFactory : public RegexFactory public: bool extended; PosixFactory(Module* m) : RegexFactory(m, "regex/posix") {} - Regex* Create(const std::string& expr) CXX11_OVERRIDE + Regex* Create(const std::string& expr) override { return new POSIXRegex(expr, extended); } @@ -80,12 +80,12 @@ class ModuleRegexPOSIX : public Module { } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("Regex Provider Module for POSIX Regular Expressions", VF_VENDOR); } - void ReadConfig(ConfigStatus& status) CXX11_OVERRIDE + void ReadConfig(ConfigStatus& status) override { ref.extended = ServerInstance->Config->ConfValue("posix")->getBool("extended"); } diff --git a/src/modules/extra/m_regex_re2.cpp b/src/modules/extra/m_regex_re2.cpp index 4bcf287ca..0cc341a35 100644 --- a/src/modules/extra/m_regex_re2.cpp +++ b/src/modules/extra/m_regex_re2.cpp @@ -52,7 +52,7 @@ class RE2Regex : public Regex } } - bool Matches(const std::string& text) CXX11_OVERRIDE + bool Matches(const std::string& text) override { return RE2::FullMatch(text, regexcl); } @@ -62,7 +62,7 @@ class RE2Factory : public RegexFactory { public: RE2Factory(Module* m) : RegexFactory(m, "regex/re2") { } - Regex* Create(const std::string& expr) CXX11_OVERRIDE + Regex* Create(const std::string& expr) override { return new RE2Regex(expr); } @@ -77,7 +77,7 @@ class ModuleRegexRE2 : public Module { } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("Regex Provider Module for RE2", VF_VENDOR); } diff --git a/src/modules/extra/m_regex_stdlib.cpp b/src/modules/extra/m_regex_stdlib.cpp index 42e5c8bf1..4065ec014 100644 --- a/src/modules/extra/m_regex_stdlib.cpp +++ b/src/modules/extra/m_regex_stdlib.cpp @@ -39,7 +39,7 @@ class StdRegex : public Regex } } - bool Matches(const std::string& text) CXX11_OVERRIDE + bool Matches(const std::string& text) override { return std::regex_search(text, regexcl); } @@ -50,7 +50,7 @@ class StdRegexFactory : public RegexFactory public: std::regex::flag_type regextype; StdRegexFactory(Module* m) : RegexFactory(m, "regex/stdregex") {} - Regex* Create(const std::string& expr) CXX11_OVERRIDE + Regex* Create(const std::string& expr) override { return new StdRegex(expr, regextype); } @@ -64,12 +64,12 @@ public: { } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("Regex Provider Module for std::regex", VF_VENDOR); } - void ReadConfig(ConfigStatus& status) CXX11_OVERRIDE + void ReadConfig(ConfigStatus& status) override { ConfigTag* Conf = ServerInstance->Config->ConfValue("stdregex"); std::string regextype = Conf->getString("type", "ecmascript"); diff --git a/src/modules/extra/m_regex_tre.cpp b/src/modules/extra/m_regex_tre.cpp index aa3f1d41e..8bec3a908 100644 --- a/src/modules/extra/m_regex_tre.cpp +++ b/src/modules/extra/m_regex_tre.cpp @@ -60,7 +60,7 @@ public: regfree(®buf); } - bool Matches(const std::string& text) CXX11_OVERRIDE + bool Matches(const std::string& text) override { return (regexec(®buf, text.c_str(), 0, NULL, 0) == 0); } @@ -70,7 +70,7 @@ class TREFactory : public RegexFactory { public: TREFactory(Module* m) : RegexFactory(m, "regex/tre") {} - Regex* Create(const std::string& expr) CXX11_OVERRIDE + Regex* Create(const std::string& expr) override { return new TRERegex(expr); } @@ -85,7 +85,7 @@ class ModuleRegexTRE : public Module { } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("Regex Provider Module for TRE Regular Expressions", VF_VENDOR); } diff --git a/src/modules/extra/m_sqlite3.cpp b/src/modules/extra/m_sqlite3.cpp index 4558e087a..e31a41c5c 100644 --- a/src/modules/extra/m_sqlite3.cpp +++ b/src/modules/extra/m_sqlite3.cpp @@ -58,12 +58,12 @@ class SQLite3Result : public SQL::Result { } - int Rows() CXX11_OVERRIDE + int Rows() override { return rows; } - bool GetRow(SQL::Row& result) CXX11_OVERRIDE + bool GetRow(SQL::Row& result) override { if (currentrow < rows) { @@ -78,12 +78,12 @@ class SQLite3Result : public SQL::Result } } - void GetCols(std::vector<std::string>& result) CXX11_OVERRIDE + void GetCols(std::vector<std::string>& result) override { result.assign(columns.begin(), columns.end()); } - bool HasColumn(const std::string& column, size_t& index) CXX11_OVERRIDE + bool HasColumn(const std::string& column, size_t& index) override { for (size_t i = 0; i < columns.size(); ++i) { @@ -172,13 +172,13 @@ class SQLConn : public SQL::Provider sqlite3_finalize(stmt); } - void Submit(SQL::Query* query, const std::string& q) CXX11_OVERRIDE + void Submit(SQL::Query* query, const std::string& q) override { Query(query, q); delete query; } - void Submit(SQL::Query* query, const std::string& q, const SQL::ParamList& p) CXX11_OVERRIDE + void Submit(SQL::Query* query, const std::string& q, const SQL::ParamList& p) override { std::string res; unsigned int param = 0; @@ -199,7 +199,7 @@ class SQLConn : public SQL::Provider Submit(query, res); } - void Submit(SQL::Query* query, const std::string& q, const SQL::ParamMap& p) CXX11_OVERRIDE + void Submit(SQL::Query* query, const std::string& q, const SQL::ParamMap& p) override { std::string res; for(std::string::size_type i = 0; i < q.length(); i++) @@ -248,7 +248,7 @@ class ModuleSQLite3 : public Module conns.clear(); } - void ReadConfig(ConfigStatus& status) CXX11_OVERRIDE + void ReadConfig(ConfigStatus& status) override { ClearConns(); ConfigTagList tags = ServerInstance->Config->ConfTags("database"); @@ -262,7 +262,7 @@ class ModuleSQLite3 : public Module } } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("sqlite3 provider", VF_VENDOR); } diff --git a/src/modules/extra/m_ssl_gnutls.cpp b/src/modules/extra/m_ssl_gnutls.cpp index f5711cbd7..8317ed93d 100644 --- a/src/modules/extra/m_ssl_gnutls.cpp +++ b/src/modules/extra/m_ssl_gnutls.cpp @@ -1070,12 +1070,12 @@ info_done_dealloc: Handshake(sock); } - void OnStreamSocketClose(StreamSocket* user) CXX11_OVERRIDE + void OnStreamSocketClose(StreamSocket* user) override { CloseSession(); } - int OnStreamSocketRead(StreamSocket* user, std::string& recvq) CXX11_OVERRIDE + int OnStreamSocketRead(StreamSocket* user, std::string& recvq) override { // Finish handshake if needed int prepret = PrepareIO(user); @@ -1113,7 +1113,7 @@ info_done_dealloc: } } - int OnStreamSocketWrite(StreamSocket* user, StreamSocket::SendQueue& sendq) CXX11_OVERRIDE + int OnStreamSocketWrite(StreamSocket* user, StreamSocket::SendQueue& sendq) override { // Finish handshake if needed int prepret = PrepareIO(user); @@ -1176,7 +1176,7 @@ info_done_dealloc: return 1; } - void GetCiphersuite(std::string& out) const CXX11_OVERRIDE + void GetCiphersuite(std::string& out) const override { if (!IsHandshakeDone()) return; @@ -1186,7 +1186,7 @@ info_done_dealloc: out.append(UnknownIfNULL(gnutls_mac_get_name(gnutls_mac_get(sess)))); } - bool GetServerName(std::string& out) const CXX11_OVERRIDE + bool GetServerName(std::string& out) const override { std::vector<char> nameBuffer; size_t nameLength = 0; @@ -1245,12 +1245,12 @@ class GnuTLSIOHookProvider : public IOHookProvider ServerInstance->Modules->DelService(*this); } - void OnAccept(StreamSocket* sock, irc::sockets::sockaddrs* client, irc::sockets::sockaddrs* server) CXX11_OVERRIDE + void OnAccept(StreamSocket* sock, irc::sockets::sockaddrs* client, irc::sockets::sockaddrs* server) override { new GnuTLSIOHook(this, sock, GNUTLS_SERVER); } - void OnConnect(StreamSocket* sock) CXX11_OVERRIDE + void OnConnect(StreamSocket* sock) override { new GnuTLSIOHook(this, sock, GNUTLS_CLIENT); } @@ -1345,14 +1345,14 @@ class ModuleSSLGnuTLS : public Module thismod = this; } - void init() CXX11_OVERRIDE + void init() override { ServerInstance->Logs->Log(MODNAME, LOG_DEFAULT, "GnuTLS lib version %s module was compiled for " GNUTLS_VERSION, gnutls_check_version(NULL)); ReadProfiles(); ServerInstance->GenRandom = RandGen::Call; } - void OnModuleRehash(User* user, const std::string ¶m) CXX11_OVERRIDE + void OnModuleRehash(User* user, const std::string ¶m) override { if(param != "ssl") return; @@ -1372,7 +1372,7 @@ class ModuleSSLGnuTLS : public Module ServerInstance->GenRandom = &InspIRCd::DefaultGenRandom; } - void OnCleanup(ExtensionItem::ExtensibleType type, Extensible* item) CXX11_OVERRIDE + void OnCleanup(ExtensionItem::ExtensibleType type, Extensible* item) override { if (type == ExtensionItem::EXT_USER) { @@ -1387,12 +1387,12 @@ class ModuleSSLGnuTLS : public Module } } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("Provides SSL support for clients", VF_VENDOR); } - ModResult OnCheckReady(LocalUser* user) CXX11_OVERRIDE + ModResult OnCheckReady(LocalUser* user) override { const GnuTLSIOHook* const iohook = static_cast<GnuTLSIOHook*>(user->eh.GetModHook(this)); if ((iohook) && (!iohook->IsHandshakeDone())) diff --git a/src/modules/extra/m_ssl_mbedtls.cpp b/src/modules/extra/m_ssl_mbedtls.cpp index 75b25fbc4..2786cd129 100644 --- a/src/modules/extra/m_ssl_mbedtls.cpp +++ b/src/modules/extra/m_ssl_mbedtls.cpp @@ -677,12 +677,12 @@ class mbedTLSIOHook : public SSLIOHook Handshake(sock); } - void OnStreamSocketClose(StreamSocket* sock) CXX11_OVERRIDE + void OnStreamSocketClose(StreamSocket* sock) override { CloseSession(); } - int OnStreamSocketRead(StreamSocket* sock, std::string& recvq) CXX11_OVERRIDE + int OnStreamSocketRead(StreamSocket* sock, std::string& recvq) override { // Finish handshake if needed int prepret = PrepareIO(sock); @@ -726,7 +726,7 @@ class mbedTLSIOHook : public SSLIOHook } } - int OnStreamSocketWrite(StreamSocket* sock, StreamSocket::SendQueue& sendq) CXX11_OVERRIDE + int OnStreamSocketWrite(StreamSocket* sock, StreamSocket::SendQueue& sendq) override { // Finish handshake if needed int prepret = PrepareIO(sock); @@ -778,7 +778,7 @@ class mbedTLSIOHook : public SSLIOHook return 1; } - void GetCiphersuite(std::string& out) const CXX11_OVERRIDE + void GetCiphersuite(std::string& out) const override { if (!IsHandshakeDone()) return; @@ -793,7 +793,7 @@ class mbedTLSIOHook : public SSLIOHook out.append(ciphersuitestr + skip); } - bool GetServerName(std::string& out) const CXX11_OVERRIDE + bool GetServerName(std::string& out) const override { // TODO: Implement SNI support. return false; @@ -820,12 +820,12 @@ class mbedTLSIOHookProvider : public IOHookProvider ServerInstance->Modules->DelService(*this); } - void OnAccept(StreamSocket* sock, irc::sockets::sockaddrs* client, irc::sockets::sockaddrs* server) CXX11_OVERRIDE + void OnAccept(StreamSocket* sock, irc::sockets::sockaddrs* client, irc::sockets::sockaddrs* server) override { new mbedTLSIOHook(this, sock, true); } - void OnConnect(StreamSocket* sock) CXX11_OVERRIDE + void OnConnect(StreamSocket* sock) override { new mbedTLSIOHook(this, sock, false); } @@ -912,7 +912,7 @@ class ModuleSSLmbedTLS : public Module } public: - void init() CXX11_OVERRIDE + void init() override { char verbuf[16]; // Should be at least 9 bytes in size mbedtls_version_get_string(verbuf); @@ -923,7 +923,7 @@ class ModuleSSLmbedTLS : public Module ReadProfiles(); } - void OnModuleRehash(User* user, const std::string ¶m) CXX11_OVERRIDE + void OnModuleRehash(User* user, const std::string ¶m) override { if (param != "ssl") return; @@ -938,7 +938,7 @@ class ModuleSSLmbedTLS : public Module } } - void OnCleanup(ExtensionItem::ExtensibleType type, Extensible* item) CXX11_OVERRIDE + void OnCleanup(ExtensionItem::ExtensibleType type, Extensible* item) override { if (type != ExtensionItem::EXT_USER) return; @@ -952,7 +952,7 @@ class ModuleSSLmbedTLS : public Module } } - ModResult OnCheckReady(LocalUser* user) CXX11_OVERRIDE + ModResult OnCheckReady(LocalUser* user) override { const mbedTLSIOHook* const iohook = static_cast<mbedTLSIOHook*>(user->eh.GetModHook(this)); if ((iohook) && (!iohook->IsHandshakeDone())) @@ -960,7 +960,7 @@ class ModuleSSLmbedTLS : public Module return MOD_RES_PASSTHRU; } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("Provides SSL support via mbedTLS (PolarSSL)", VF_VENDOR); } diff --git a/src/modules/extra/m_ssl_openssl.cpp b/src/modules/extra/m_ssl_openssl.cpp index 5f61c71a9..125190c7d 100644 --- a/src/modules/extra/m_ssl_openssl.cpp +++ b/src/modules/extra/m_ssl_openssl.cpp @@ -695,12 +695,12 @@ class OpenSSLIOHook : public SSLIOHook Handshake(sock); } - void OnStreamSocketClose(StreamSocket* user) CXX11_OVERRIDE + void OnStreamSocketClose(StreamSocket* user) override { CloseSession(); } - int OnStreamSocketRead(StreamSocket* user, std::string& recvq) CXX11_OVERRIDE + int OnStreamSocketRead(StreamSocket* user, std::string& recvq) override { // Finish handshake if needed int prepret = PrepareIO(user); @@ -760,7 +760,7 @@ class OpenSSLIOHook : public SSLIOHook } } - int OnStreamSocketWrite(StreamSocket* user, StreamSocket::SendQueue& sendq) CXX11_OVERRIDE + int OnStreamSocketWrite(StreamSocket* user, StreamSocket::SendQueue& sendq) override { // Finish handshake if needed int prepret = PrepareIO(user); @@ -823,7 +823,7 @@ class OpenSSLIOHook : public SSLIOHook return 1; } - void GetCiphersuite(std::string& out) const CXX11_OVERRIDE + void GetCiphersuite(std::string& out) const override { if (!IsHandshakeDone()) return; @@ -831,7 +831,7 @@ class OpenSSLIOHook : public SSLIOHook out.append(SSL_get_cipher(sess)); } - bool GetServerName(std::string& out) const CXX11_OVERRIDE + bool GetServerName(std::string& out) const override { const char* name = SSL_get_servername(sess, TLSEXT_NAMETYPE_host_name); if (!name) @@ -914,12 +914,12 @@ class OpenSSLIOHookProvider : public IOHookProvider ServerInstance->Modules->DelService(*this); } - void OnAccept(StreamSocket* sock, irc::sockets::sockaddrs* client, irc::sockets::sockaddrs* server) CXX11_OVERRIDE + void OnAccept(StreamSocket* sock, irc::sockets::sockaddrs* client, irc::sockets::sockaddrs* server) override { new OpenSSLIOHook(this, sock, profile.CreateServerSession()); } - void OnConnect(StreamSocket* sock) CXX11_OVERRIDE + void OnConnect(StreamSocket* sock) override { new OpenSSLIOHook(this, sock, profile.CreateClientSession()); } @@ -1010,7 +1010,7 @@ class ModuleSSLOpenSSL : public Module #endif } - void init() CXX11_OVERRIDE + void init() override { ServerInstance->Logs->Log(MODNAME, LOG_DEFAULT, "OpenSSL lib version \"%s\" module was compiled for \"" OPENSSL_VERSION_TEXT "\"", OpenSSL_version(OPENSSL_VERSION)); @@ -1023,7 +1023,7 @@ class ModuleSSLOpenSSL : public Module ReadProfiles(); } - void OnModuleRehash(User* user, const std::string ¶m) CXX11_OVERRIDE + void OnModuleRehash(User* user, const std::string ¶m) override { if (param != "ssl") return; @@ -1038,7 +1038,7 @@ class ModuleSSLOpenSSL : public Module } } - void OnCleanup(ExtensionItem::ExtensibleType type, Extensible* item) CXX11_OVERRIDE + void OnCleanup(ExtensionItem::ExtensibleType type, Extensible* item) override { if (type == ExtensionItem::EXT_USER) { @@ -1053,7 +1053,7 @@ class ModuleSSLOpenSSL : public Module } } - ModResult OnCheckReady(LocalUser* user) CXX11_OVERRIDE + ModResult OnCheckReady(LocalUser* user) override { const OpenSSLIOHook* const iohook = static_cast<OpenSSLIOHook*>(user->eh.GetModHook(this)); if ((iohook) && (!iohook->IsHandshakeDone())) @@ -1061,7 +1061,7 @@ class ModuleSSLOpenSSL : public Module return MOD_RES_PASSTHRU; } - Version GetVersion() CXX11_OVERRIDE + Version GetVersion() override { return Version("Provides SSL support for clients", VF_VENDOR); } |
