Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

crypto: use uv_thread_self()

  • Loading branch information...
commit bec863b7de8ab45cf599372b16274fa526bd86a0 1 parent dd1b947
@bnoordhuis bnoordhuis authored
Showing with 1 addition and 18 deletions.
  1. +1 −18 src/node_crypto.cc
View
19 src/node_crypto.cc
@@ -33,17 +33,8 @@
#endif
#include <stdlib.h>
-
#include <errno.h>
-/* Sigh. */
-#ifdef _WIN32
-# include <windows.h>
-#else
-# include <pthread.h>
-#endif
-
-
#if OPENSSL_VERSION_NUMBER >= 0x10000000L
# define OPENSSL_CONST const
#else
@@ -94,15 +85,7 @@ static uv_rwlock_t* locks;
static void crypto_threadid_cb(CRYPTO_THREADID* tid) {
- unsigned long val;
-
-#ifdef _WIN32
- val = static_cast<unsigned long>(GetCurrentThreadId());
-#else
- val = (unsigned long) pthread_self();
-#endif
-
- CRYPTO_THREADID_set_numeric(tid, val);
+ CRYPTO_THREADID_set_numeric(tid, uv_thread_self());
}
Please sign in to comment.
Something went wrong with that request. Please try again.