mirror of
https://github.com/libp2p/go-openssl.git
synced 2026-08-18 14:43:28 +08:00
set callback thread id on windows
This commit is contained in:
@@ -61,12 +61,8 @@ void go_thread_locking_callback(int mode, int n, const char *file,
|
||||
}
|
||||
}
|
||||
|
||||
unsigned long go_thread_id_callback(void)
|
||||
{
|
||||
unsigned long ret;
|
||||
|
||||
ret = (unsigned long)pthread_self();
|
||||
return (ret);
|
||||
unsigned long go_thread_id_callback(void) {
|
||||
return (unsigned long)pthread_self();
|
||||
}
|
||||
*/
|
||||
import "C"
|
||||
|
||||
@@ -49,5 +49,9 @@ void go_thread_locking_callback(int mode, int n, const char *file,
|
||||
LeaveCriticalSection(&goopenssl_locks[n]);
|
||||
}
|
||||
}
|
||||
|
||||
unsigned long go_thread_id_callback(void) {
|
||||
return (unsigned long)GetCurrentThreadId();
|
||||
}
|
||||
*/
|
||||
import "C"
|
||||
|
||||
Reference in New Issue
Block a user