From dce92611f3ff33e7db0a7234d611f5bffb0cc45f Mon Sep 17 00:00:00 2001 From: leak Date: Sun, 20 Jul 2014 00:39:43 +0200 Subject: Refactored singletons to enable proper deconstruction during shutdown --- src/server/shared/Logging/Log.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/server/shared/Logging/Log.h') diff --git a/src/server/shared/Logging/Log.h b/src/server/shared/Logging/Log.h index e739c9eaf4e..8ae8db5bf5f 100644 --- a/src/server/shared/Logging/Log.h +++ b/src/server/shared/Logging/Log.h @@ -43,15 +43,15 @@ class Log static Log* instance(boost::asio::io_service* ioService = nullptr) { - static Log* instance = new Log(); + static Log instance; if (ioService != nullptr) { - instance->_ioService = ioService; - instance->_strand = new boost::asio::strand(*ioService); + instance._ioService = ioService; + instance._strand = new boost::asio::strand(*ioService); } - return instance; + return &instance; } void LoadFromConfig(); -- cgit v1.2.3