diff options
author | Peter Powell <petpow@saberuk.com> | 2019-10-17 17:17:39 +0100 |
---|---|---|
committer | Peter Powell <petpow@saberuk.com> | 2019-10-17 17:17:39 +0100 |
commit | e3deb783406e15cf496afab6971a908215b2ea81 (patch) | |
tree | 93a08baff27b27f541bd32dc79a594460100c194 /src/inspircd.cpp | |
parent | 08393c002803b93ac53a6a1a0a5272e76b6ae5e4 (diff) |
Add an event which is fired when the server shuts down.
Diffstat (limited to 'src/inspircd.cpp')
-rw-r--r-- | src/inspircd.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/inspircd.cpp b/src/inspircd.cpp index 70e5fcf38..f35482f61 100644 --- a/src/inspircd.cpp +++ b/src/inspircd.cpp @@ -93,8 +93,11 @@ void InspIRCd::Cleanup() } ports.clear(); - // Disconnect all local users + // Tell modules that we're shutting down. const std::string quitmsg = "Server shutting down"; + FOREACH_MOD(OnShutdown, (quitmsg)); + + // Disconnect all local users const UserManager::LocalList& list = Users.GetLocalUsers(); while (!list.empty()) ServerInstance->Users.QuitUser(list.front(), quitmsg); |