diff options
-rw-r--r-- | src/account-server/main-account.cpp | 3 | ||||
-rw-r--r-- | src/game-server/main-game.cpp | 6 |
2 files changed, 3 insertions, 6 deletions
diff --git a/src/account-server/main-account.cpp b/src/account-server/main-account.cpp index eec8b9ed..b4f4c28b 100644 --- a/src/account-server/main-account.cpp +++ b/src/account-server/main-account.cpp @@ -138,9 +138,6 @@ static void initialize() signal(SIGINT, closeGracefully); signal(SIGTERM, closeGracefully); - // Set enet to quit on exit. - atexit(enet_deinitialize); - std::string logFile = Configuration::getValue("log_accountServerFile", DEFAULT_LOG_FILE); diff --git a/src/game-server/main-game.cpp b/src/game-server/main-game.cpp index 01cb6604..d7ce8c5d 100644 --- a/src/game-server/main-game.cpp +++ b/src/game-server/main-game.cpp @@ -219,9 +219,6 @@ static void initializeServer() exit(EXIT_NET_EXCEPTION); } - // Set enet to quit on exit. - atexit(enet_deinitialize); - // Pre-calculate the needed trigomic function values utils::math::init(); @@ -241,6 +238,9 @@ static void deinitializeServer() // Stop world timer worldTimer.stop(); + // Quit ENet + enet_deinitialize(); + // Destroy message handlers delete gameHandler; delete accountHandler; |