diff options
author | Roger Meier <roger@apache.org> | 2015-11-29 16:58:15 +0100 |
---|---|---|
committer | Roger Meier <roger@apache.org> | 2015-11-29 16:58:15 +0100 |
commit | 54a2e6452fbaed5a82e3b9a8504cf2850d4da191 (patch) | |
tree | 9e5f26a56fa9efcf53591458e7f3dac615f29541 /lib/cpp | |
parent | 9921300deeb5906cb9c7df33020d19abf9894910 (diff) | |
download | thrift-54a2e6452fbaed5a82e3b9a8504cf2850d4da191.tar.gz |
THRIFT-3206 Fix Visual Studio build failure due 'pthread_self': identifier not found
Patch: Paweł Janicki
Diffstat (limited to 'lib/cpp')
-rw-r--r-- | lib/cpp/src/thrift/transport/TSSLSocket.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/cpp/src/thrift/transport/TSSLSocket.cpp b/lib/cpp/src/thrift/transport/TSSLSocket.cpp index 6e9a4de0f..8e5642678 100644 --- a/lib/cpp/src/thrift/transport/TSSLSocket.cpp +++ b/lib/cpp/src/thrift/transport/TSSLSocket.cpp @@ -74,7 +74,11 @@ static void callbackLocking(int mode, int n, const char*, int) { #if (OPENSSL_VERSION_NUMBER < OPENSSL_VERSION_NO_THREAD_ID) static unsigned long callbackThreadID() { +#ifdef _WIN32 + return (unsigned long)GetCurrentThreadId(); +#else return (unsigned long)pthread_self(); +#endif } #endif |