diff options
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r-- | src/modules/m_spanningtree/main.cpp | 7 | ||||
-rw-r--r-- | src/modules/m_spanningtree/main.h | 1 |
2 files changed, 8 insertions, 0 deletions
diff --git a/src/modules/m_spanningtree/main.cpp b/src/modules/m_spanningtree/main.cpp index 3e992f39f..fbc6ad40c 100644 --- a/src/modules/m_spanningtree/main.cpp +++ b/src/modules/m_spanningtree/main.cpp @@ -793,6 +793,13 @@ void ModuleSpanningTree::OnMode(User* source, User* u, Channel* c, const Modes:: } } +void ModuleSpanningTree::OnShutdown(const std::string& reason) +{ + const TreeServer::ChildServers& children = Utils->TreeRoot->GetChildren(); + while (!children.empty()) + children.front()->SQuit(reason, true); +} + CullResult ModuleSpanningTree::cull() { if (Utils) diff --git a/src/modules/m_spanningtree/main.h b/src/modules/m_spanningtree/main.h index bc31a9aea..3a61927b4 100644 --- a/src/modules/m_spanningtree/main.h +++ b/src/modules/m_spanningtree/main.h @@ -212,6 +212,7 @@ class ModuleSpanningTree void OnUnloadModule(Module* mod) CXX11_OVERRIDE; ModResult OnAcceptConnection(int newsock, ListenSocket* from, irc::sockets::sockaddrs* client, irc::sockets::sockaddrs* server) CXX11_OVERRIDE; void OnMode(User* source, User* u, Channel* c, const Modes::ChangeList& modes, ModeParser::ModeProcessFlag processflags) CXX11_OVERRIDE; + void OnShutdown(const std::string& reason) CXX11_OVERRIDE; CullResult cull() CXX11_OVERRIDE; ~ModuleSpanningTree(); Version GetVersion() CXX11_OVERRIDE; |