We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2ae7b98 commit 186768aCopy full SHA for 186768a
thread_setup_unix.c
@@ -9,6 +9,8 @@ static pthread_mutex_t *mutex_buf = NULL;
9
10
static pthread_key_t destructor_key;
11
12
+static char dummy;
13
+
14
/* Used by unit tests. */
15
volatile unsigned int go_openssl_threads_cleaned_up = 0;
16
@@ -29,7 +31,7 @@ static void thread_id(GO_CRYPTO_THREADID_PTR tid)
29
31
// least once on any thread with associated error state. The thread-local
30
32
// variable needs to be set to a non-NULL value so that the destructor will
33
// be called when the thread exits. The actual value does not matter.
- (void) pthread_setspecific(destructor_key, (void*)1);
34
+ (void) pthread_setspecific(destructor_key, &dummy);
35
}
36
37
static void cleanup_thread_state(void *ignored)
0 commit comments