From 067aa4c28bb1064f16312766f1b9688942d70a15 Mon Sep 17 00:00:00 2001 From: Gregory Pakosz Date: Tue, 4 Dec 2018 14:47:24 +0100 Subject: [PATCH] Do not define GTEST_IS_THREADSAFE within GTEST_HAS_SEH --- googletest/include/gtest/internal/gtest-port.h | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/googletest/include/gtest/internal/gtest-port.h b/googletest/include/gtest/internal/gtest-port.h index 4cd74fb6..8d1b6191 100644 --- a/googletest/include/gtest/internal/gtest-port.h +++ b/googletest/include/gtest/internal/gtest-port.h @@ -785,13 +785,17 @@ typedef struct _RTL_CRITICAL_SECTION GTEST_CRITICAL_SECTION; # define GTEST_HAS_SEH 0 # endif -#define GTEST_IS_THREADSAFE \ - (GTEST_HAS_MUTEX_AND_THREAD_LOCAL_ \ - || (GTEST_OS_WINDOWS && !GTEST_OS_WINDOWS_PHONE && !GTEST_OS_WINDOWS_RT) \ - || GTEST_HAS_PTHREAD) - #endif // GTEST_HAS_SEH +#ifndef GTEST_IS_THREADSAFE + +# define GTEST_IS_THREADSAFE \ + ( GTEST_HAS_MUTEX_AND_THREAD_LOCAL_ \ + || (GTEST_OS_WINDOWS && !GTEST_OS_WINDOWS_PHONE && !GTEST_OS_WINDOWS_RT) \ + || GTEST_HAS_PTHREAD) + +#endif // GTEST_IS_THREADSAFE + // GTEST_API_ qualifies all symbols that must be exported. The definitions below // are guarded by #ifndef to give embedders a chance to define GTEST_API_ in // gtest/internal/custom/gtest-port.h