From d9f48db5db2e9d460e841f1f98426fe6868010c5 Mon Sep 17 00:00:00 2001 From: Bart Trzynadlowski Date: Sat, 9 Mar 2024 20:56:50 -0800 Subject: [PATCH] CLogger: destructor needs to be virtual --- Src/OSD/Logger.h | 32 ++++++++++++++++++-------------- 1 file changed, 18 insertions(+), 14 deletions(-) diff --git a/Src/OSD/Logger.h b/Src/OSD/Logger.h index 15aeb0d..e75aaf8 100644 --- a/Src/OSD/Logger.h +++ b/Src/OSD/Logger.h @@ -27,9 +27,9 @@ * default logger (CFileLogger). */ -#ifndef INCLUDED_LOGGER_H -#define INCLUDED_LOGGER_H - +#ifndef INCLUDED_LOGGER_H +#define INCLUDED_LOGGER_H + #include "Types.h" #include "Version.h" #include "Util/NewConfig.h" @@ -56,14 +56,18 @@ class CLogger { public: - // Log level in ascending order - enum LogLevel: int - { - All = 0, - Debug, - Info, - Error - }; + // Log level in ascending order + enum LogLevel: int + { + All = 0, + Debug, + Info, + Error + }; + + virtual ~CLogger() + { + } /* * DebugLog(fmt, ...): @@ -276,7 +280,7 @@ extern void SetLogger(std::shared_ptr logger); * GetLogger(void): * * Returns: - * Current logger object (null pointer if not set). + * Current logger object (null pointer if not set). */ extern std::shared_ptr GetLogger(void); @@ -289,5 +293,5 @@ extern std::shared_ptr GetLogger(void); */ std::shared_ptr CreateLogger(const Util::Config::Node &config); - -#endif // INCLUDED_LOGGER_H + +#endif // INCLUDED_LOGGER_H