Fix compilation on MinGW with native threads
This commit is contained in:
@@ -1295,9 +1295,16 @@ TEST(WindowsTypesTest, HANDLEIsVoidStar) {
|
||||
StaticAssertTypeEq<HANDLE, void*>();
|
||||
}
|
||||
|
||||
#if GTEST_OS_WINDOWS_MINGW
|
||||
TEST(WindowsTypesTest, _CRITICAL_SECTIONIs_CRITICAL_SECTION) {
|
||||
StaticAssertTypeEq<CRITICAL_SECTION, _CRITICAL_SECTION>();
|
||||
}
|
||||
#else
|
||||
TEST(WindowsTypesTest, CRITICAL_SECTIONIs_RTL_CRITICAL_SECTION) {
|
||||
StaticAssertTypeEq<CRITICAL_SECTION, _RTL_CRITICAL_SECTION>();
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif // GTEST_OS_WINDOWS
|
||||
|
||||
} // namespace internal
|
||||
|
||||
@@ -442,7 +442,7 @@ class FormatEpochTimeInMillisAsIso8601Test : public Test {
|
||||
// tzset() distinguishes between the TZ variable being present and empty
|
||||
// and not being present, so we have to consider the case of time_zone
|
||||
// being NULL.
|
||||
#if _MSC_VER
|
||||
#if _MSC_VER || GTEST_OS_WINDOWS_MINGW
|
||||
// ...Unless it's MSVC, whose standard library's _putenv doesn't
|
||||
// distinguish between an empty and a missing variable.
|
||||
const std::string env_var =
|
||||
|
||||
Reference in New Issue
Block a user