summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/chatServer.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/chatServer.cpp b/src/chatServer.cpp
index 11d4919..8e9a3ab 100644
--- a/src/chatServer.cpp
+++ b/src/chatServer.cpp
@@ -6,6 +6,9 @@
CChatServer::CChatServer(uint16_t port)
: m_port(port) {
+ if (std::atexit([]() { g_pChatServer->cleanup(); }))
+ log(ERR, "Failed to register CChatServer atexit handler, dtors will not be called");
+
log(LOG, "ChatServer: initialized");
};