@@ -884,12 +884,12 @@ class auto_logger_file__
884884 int64_t m_log_size{ 0 };
885885};
886886
887- #ifndef DISABLE_LOGGER_THREAD_SAFE
888- #define LOGGER_LOCKS_ () std::lock_guard \
887+ #ifndef DISABLE_XLOGGER_THREAD_SAFE
888+ #define XLOGGER_LOCKS_ () std::lock_guard \
889889 lock (logger_aux__::lock_single<std::mutex>())
890890#else
891- #define LOGGER_LOCKS_ () ((void )0 )
892- #endif // LOGGER_THREAD_SAFE
891+ #define XLOGGER_LOCKS_ () ((void )0 )
892+ #endif // DISABLE_XLOGGER_THREAD_SAFE
893893
894894#ifndef LOGGER_DBG_VIEW_
895895#if defined(WIN32) && \
@@ -933,12 +933,12 @@ inline void logger_output_console__([[maybe_unused]] const logger_level__& level
933933{
934934#if defined(WIN32)
935935
936- #if !defined(DISABLE_LOGGER_TO_CONSOLE ) || !defined(DISABLE_LOGGER_TO_DBGVIEW )
936+ #if !defined(DISABLE_XLOGGER_TO_CONSOLE ) || !defined(DISABLE_XLOGGER_TO_DBGVIEW )
937937 std::wstring title = *logger_aux__::utf8_utf16 (prefix);
938938 std::wstring msg = *logger_aux__::utf8_utf16 (message);
939939#endif
940940
941- #if !defined(DISABLE_LOGGER_TO_CONSOLE )
941+ #if !defined(DISABLE_XLOGGER_TO_CONSOLE )
942942 HANDLE handle_stdout = GetStdHandle (STD_OUTPUT_HANDLE);
943943 CONSOLE_SCREEN_BUFFER_INFO csbi;
944944 GetConsoleScreenBufferInfo (handle_stdout, &csbi);
@@ -973,11 +973,11 @@ inline void logger_output_console__([[maybe_unused]] const logger_level__& level
973973 SetConsoleTextAttribute (handle_stdout, csbi.wAttributes );
974974#endif
975975
976- #if !defined(DISABLE_LOGGER_TO_DBGVIEW )
976+ #if !defined(DISABLE_XLOGGER_TO_DBGVIEW )
977977 LOGGER_DBG_VIEW_ (title + msg);
978978#endif
979979
980- #elif !defined(DISABLE_LOGGER_TO_CONSOLE )
980+ #elif !defined(DISABLE_XLOGGER_TO_CONSOLE )
981981 std::string out;
982982
983983 switch (level)
@@ -1091,7 +1091,7 @@ inline void logger_writer__(int64_t time, const logger_level__& level,
10911091 const std::string& message,
10921092 [[maybe_unused]] bool disable_cout = false ) noexcept
10931093{
1094- LOGGER_LOCKS_ ();
1094+ XLOGGER_LOCKS_ ();
10951095 static auto & logger = xlogger::logger_aux__::writer_single<
10961096 xlogger::auto_logger_file__>();
10971097 char ts[64 ] = { 0 };
@@ -1853,8 +1853,7 @@ class empty_logger___
18531853};
18541854} // namespace xlogger
18551855
1856- #if (defined(DEBUG) || defined(_DEBUG) || \
1857- defined (ENABLE_LOGGER)) && !defined(DISABLE_LOGGER)
1856+ #if (!defined(NDEBUG) || defined(ENABLE_XLOGGER)) && !defined(DISABLE_XLOGGER)
18581857
18591858// API for logging.
18601859namespace xlogger {
0 commit comments