diff options
| author | Adam <Adam@anope.org> | 2012-02-18 15:04:26 -0500 |
|---|---|---|
| committer | Adam <Adam@anope.org> | 2012-02-18 15:04:26 -0500 |
| commit | ee5cd8493e34a1c049066ead25e9094b30cd49b5 (patch) | |
| tree | 846c6dcd9bb2c4d721c6290a9b9d6b6ed880acdb /modules/extra/m_proxyscan.cpp | |
| parent | 41e8d276023e8fefc22fb89c2f81ae17b8222155 (diff) | |
Use C++11's explicit override feature if available
Diffstat (limited to 'modules/extra/m_proxyscan.cpp')
| -rw-r--r-- | modules/extra/m_proxyscan.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/modules/extra/m_proxyscan.cpp b/modules/extra/m_proxyscan.cpp index 37fd7c432..ea35e8f77 100644 --- a/modules/extra/m_proxyscan.cpp +++ b/modules/extra/m_proxyscan.cpp @@ -29,12 +29,12 @@ class ProxyCallbackListener : public ListenSocket { } - void OnAccept() + void OnAccept() anope_override { this->Write(ProxyCheckString); } - bool ProcessWrite() + bool ProcessWrite() anope_override { return !BufferedSocket::ProcessWrite() || this->WriteBuffer.empty() ? false : true; } @@ -45,7 +45,7 @@ class ProxyCallbackListener : public ListenSocket { } - ClientSocket *OnAccept(int fd, const sockaddrs &addr) + ClientSocket *OnAccept(int fd, const sockaddrs &addr) anope_override { return new ProxyCallbackClient(this, fd, addr); } @@ -73,7 +73,7 @@ class ProxyConnect : public ConnectionSocket proxies.erase(this); } - virtual void OnConnect() = 0; + virtual void OnConnect() anope_override = 0; virtual const Anope::string GetType() const = 0; protected: @@ -112,7 +112,7 @@ class HTTPProxyConnect : public ProxyConnect, public BufferedSocket { } - void OnConnect() + void OnConnect() anope_override { this->Write("CONNECT %s:%d HTTP/1.0", target_ip.c_str(), target_port); this->Write("Content-length: 0"); @@ -120,12 +120,12 @@ class HTTPProxyConnect : public ProxyConnect, public BufferedSocket this->Write(""); } - const Anope::string GetType() const + const Anope::string GetType() const anope_override { return "HTTP"; } - bool Read(const Anope::string &buf) + bool Read(const Anope::string &buf) anope_override { if (buf == ProxyCheckString) { @@ -143,7 +143,7 @@ class SOCKS5ProxyConnect : public ProxyConnect, public BinarySocket { } - void OnConnect() + void OnConnect() anope_override { sockaddrs target_addr; char buf[4 + sizeof(target_addr.sa4.sin_addr.s_addr) + sizeof(target_addr.sa4.sin_port)]; @@ -175,12 +175,12 @@ class SOCKS5ProxyConnect : public ProxyConnect, public BinarySocket this->Write(buf, ptr); } - const Anope::string GetType() const + const Anope::string GetType() const anope_override { return "SOCKS5"; } - bool Read(const char *buffer, size_t l) + bool Read(const char *buffer, size_t l) anope_override { if (l >= ProxyCheckString.length() && !strncmp(buffer, ProxyCheckString.c_str(), ProxyCheckString.length())) { @@ -207,7 +207,7 @@ class ModuleProxyScan : public Module { } - void Tick(time_t) + void Tick(time_t) anope_override { for (std::set<ProxyConnect *>::iterator it = ProxyConnect::proxies.begin(), it_end = ProxyConnect::proxies.end(); it != it_end; ++it) { @@ -262,7 +262,7 @@ class ModuleProxyScan : public Module delete this->listener; } - void OnReload() + void OnReload() anope_override { ConfigReader config; @@ -341,7 +341,7 @@ class ModuleProxyScan : public Module } } - void OnUserConnect(dynamic_reference<User> &user, bool &exempt) + void OnUserConnect(dynamic_reference<User> &user, bool &exempt) anope_override { if (exempt || !user || !Me->IsSynced() || !user->server->IsSynced()) return; |
