summaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2010-08-17 22:19:36 -0400
committerAdam <Adam@anope.org>2010-08-17 22:19:36 -0400
commitb180d5f975b3fd9a096a712adf9589c360831f72 (patch)
tree34952f6bb9d25653f43c90a9ca603214af4ca52c /src/main.cpp
parentfa7684b3a3eea24ab72549aded6466eb0bede5fb (diff)
Always unload socketengines/database/protocl etc modules last, and fixed a potential crash in m_mysql when unloading when not in GDB
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 8132e9d1c..df7c61c63 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -189,9 +189,7 @@ void do_restart_services()
SocketEngine->Process();
delete UplinkSock;
close_log();
- /* First don't unload protocol module, then do so */
- ModuleManager::UnloadAll(false);
- ModuleManager::UnloadAll(true);
+ ModuleManager::UnloadAll();
chdir(binary_dir.c_str());
execve(services_bin.c_str(), my_av, my_envp);
if (!readonly)
@@ -238,9 +236,7 @@ static void services_shutdown()
SocketEngine->Process();
delete UplinkSock;
FOREACH_MOD(I_OnShutdown, OnShutdown());
- /* First don't unload protocol module, then do so */
- ModuleManager::UnloadAll(false);
- ModuleManager::UnloadAll(true);
+ ModuleManager::UnloadAll();
/* just in case they weren't all removed at least run once */
ModuleRunTimeDirCleanUp();
}