diff options
author | kosak <kosak@google.com> | 2014-03-24 21:58:25 +0000 |
---|---|---|
committer | kosak <kosak@google.com> | 2014-03-24 21:58:25 +0000 |
commit | a6340420b9cee27f77c5b91bea807121914a5831 (patch) | |
tree | a761f77d59d13f7dea8e415b4e0d64ad765c6f72 /src/gtest-internal-inl.h | |
parent | ffea2d604031a8c732cec8f8de9d9f9bcfbbcf70 (diff) | |
download | googletest-a6340420b9cee27f77c5b91bea807121914a5831.tar.gz googletest-a6340420b9cee27f77c5b91bea807121914a5831.tar.bz2 googletest-a6340420b9cee27f77c5b91bea807121914a5831.zip |
Implement threading support for gtest on Windows.
Also, stop using localtime(). Instead, use localtime_r() on most systems, localtime_s() on Windows.
Diffstat (limited to 'src/gtest-internal-inl.h')
-rw-r--r-- | src/gtest-internal-inl.h | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/src/gtest-internal-inl.h b/src/gtest-internal-inl.h index 35df303c..41fadb10 100644 --- a/src/gtest-internal-inl.h +++ b/src/gtest-internal-inl.h @@ -968,32 +968,6 @@ GTEST_API_ void ParseGoogleTestFlagsOnly(int* argc, wchar_t** argv); // platform. GTEST_API_ std::string GetLastErrnoDescription(); -# if GTEST_OS_WINDOWS -// Provides leak-safe Windows kernel handle ownership. -class AutoHandle { - public: - AutoHandle() : handle_(INVALID_HANDLE_VALUE) {} - explicit AutoHandle(HANDLE handle) : handle_(handle) {} - - ~AutoHandle() { Reset(); } - - HANDLE Get() const { return handle_; } - void Reset() { Reset(INVALID_HANDLE_VALUE); } - void Reset(HANDLE handle) { - if (handle != handle_) { - if (handle_ != INVALID_HANDLE_VALUE) - ::CloseHandle(handle_); - handle_ = handle; - } - } - - private: - HANDLE handle_; - - GTEST_DISALLOW_COPY_AND_ASSIGN_(AutoHandle); -}; -# endif // GTEST_OS_WINDOWS - // Attempts to parse a string into a positive integer pointed to by the // number parameter. Returns true if that is possible. // GTEST_HAS_DEATH_TEST implies that we have ::std::string, so we can use |