From 50a94f972d26ee15fc22cce657d13023d1022905 Mon Sep 17 00:00:00 2001 From: Tiger Wang Date: Tue, 26 Jan 2021 09:41:55 +0000 Subject: Fix debug macro situation (#5114) Use the standard NDEBUG. --- src/OSSupport/IsThread.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/OSSupport/IsThread.cpp') diff --git a/src/OSSupport/IsThread.cpp b/src/OSSupport/IsThread.cpp index d60d0d9eb..4190acb26 100644 --- a/src/OSSupport/IsThread.cpp +++ b/src/OSSupport/IsThread.cpp @@ -11,7 +11,7 @@ -#if defined(_MSC_VER) && defined(_DEBUG) +#if defined(_MSC_VER) && !defined(NDEBUG) // Code adapted from MSDN: https://msdn.microsoft.com/en-us/library/xcb2z8hs.aspx const DWORD MS_VC_EXCEPTION = 0x406D1388; @@ -39,7 +39,7 @@ { } } -#endif // _MSC_VER && _DEBUG +#endif // _MSC_VER && !NDEBUG @@ -84,7 +84,7 @@ bool cIsThread::Start(void) // Initialize the thread: m_Thread = std::thread(&cIsThread::DoExecute, this); - #if defined (_MSC_VER) && defined(_DEBUG) + #if defined(_MSC_VER) && !defined(NDEBUG) if (!m_ThreadName.empty()) { SetThreadName(&m_Thread, m_ThreadName.c_str()); -- cgit v1.2.3