From 23d71d171e6e22ba5e4a909d597a54595b2a2c1f Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Wed, 5 Aug 2020 14:56:20 +0300 Subject: Do not hide compile-time thread safety warnings --- src/sync.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/sync.h b/src/sync.h index 05ff2ee8a9..c5f6893374 100644 --- a/src/sync.h +++ b/src/sync.h @@ -53,7 +53,7 @@ void LeaveCritical(); void CheckLastCritical(void* cs, std::string& lockname, const char* guardname, const char* file, int line); std::string LocksHeld(); template -void AssertLockHeldInternal(const char* pszName, const char* pszFile, int nLine, MutexType* cs) ASSERT_EXCLUSIVE_LOCK(cs); +void AssertLockHeldInternal(const char* pszName, const char* pszFile, int nLine, MutexType* cs); void AssertLockNotHeldInternal(const char* pszName, const char* pszFile, int nLine, void* cs); void DeleteLock(void* cs); bool LockStackEmpty(); @@ -69,7 +69,7 @@ inline void EnterCritical(const char* pszName, const char* pszFile, int nLine, v inline void LeaveCritical() {} inline void CheckLastCritical(void* cs, std::string& lockname, const char* guardname, const char* file, int line) {} template -inline void AssertLockHeldInternal(const char* pszName, const char* pszFile, int nLine, MutexType* cs) ASSERT_EXCLUSIVE_LOCK(cs) {} +inline void AssertLockHeldInternal(const char* pszName, const char* pszFile, int nLine, MutexType* cs) {} inline void AssertLockNotHeldInternal(const char* pszName, const char* pszFile, int nLine, void* cs) {} inline void DeleteLock(void* cs) {} inline bool LockStackEmpty() { return true; } -- cgit v1.2.3