mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-24 04:25:06 +02:00
runtime: cast to the required type for pthread_key_create
This commit is contained in:
parent
23301bfd1a
commit
9dc90531ee
1 changed files with 1 additions and 1 deletions
|
@ -7129,7 +7129,7 @@ void *Cyc_init_thread(object thread_and_thunk, int argc, object * args)
|
||||||
ck_pr_cas_int((int *)&(thd->thread_state), CYC_THREAD_STATE_NEW,
|
ck_pr_cas_int((int *)&(thd->thread_state), CYC_THREAD_STATE_NEW,
|
||||||
CYC_THREAD_STATE_RUNNABLE);
|
CYC_THREAD_STATE_RUNNABLE);
|
||||||
if (ck_pr_cas_int(&cyclone_thread_key_create, 1, 0)) {
|
if (ck_pr_cas_int(&cyclone_thread_key_create, 1, 0)) {
|
||||||
int r = pthread_key_create(&cyclone_thread_key, Cyc_end_thread);
|
int r = pthread_key_create(&cyclone_thread_key, (void (*)(void *))Cyc_end_thread);
|
||||||
assert(r == 0);
|
assert(r == 0);
|
||||||
}
|
}
|
||||||
pthread_setspecific(cyclone_thread_key, thd);
|
pthread_setspecific(cyclone_thread_key, thd);
|
||||||
|
|
Loading…
Add table
Reference in a new issue