diff options
Diffstat (limited to 'src/modules/m_spanningtree/utils.h')
-rw-r--r-- | src/modules/m_spanningtree/utils.h | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/src/modules/m_spanningtree/utils.h b/src/modules/m_spanningtree/utils.h index 27df8ddbf..1022c1796 100644 --- a/src/modules/m_spanningtree/utils.h +++ b/src/modules/m_spanningtree/utils.h @@ -21,6 +21,7 @@ class TreeServer; class TreeSocket; class Link; class ModuleSpanningTree; +class SpanningTreeUtilities; /* This hash_map holds the hash equivalent of the server * tree, used for rapid linear lookups. @@ -35,6 +36,22 @@ class ModuleSpanningTree; #endif #endif +/* + * Initialises server connections + */ +class ServerSocketListener : public ListenSocketBase +{ + SpanningTreeUtilities *Utils; + + public: + ServerSocketListener(InspIRCd* Instance, SpanningTreeUtilities *u, int port, char* addr) : ListenSocketBase(Instance, port, addr) + { + this->Utils = u; + } + + virtual void OnAcceptReady(const std::string &ipconnectedto, int nfd, const std::string &incomingip); +}; + typedef std::map<TreeServer*,TreeServer*> TreeServerList; /** A group of modules that implement BufferedSocketHook @@ -69,9 +86,10 @@ class SpanningTreeUtilities : public classbase /** Make snomasks +CQ quiet during bursts and splits */ bool quiet_bursts; + /** Socket bindings for listening sockets */ - std::vector<TreeSocket*> Bindings; + std::vector<ServerSocketListener *> Bindings; /* Number of seconds that a server can go without ping * before opers are warned of high latency. */ |