mirror of
https://github.com/fluencelabs/musl
synced 2025-06-28 22:22:01 +00:00
use weak symbols for the POSIX functions that will be used by C threads
The intent of this is to avoid name space pollution of the C threads implementation. This has two sides to it. First we have to provide symbols that wouldn't pollute the name space for the C threads implementation. Second we have to clean up some internal uses of POSIX functions such that they don't implicitly drag in such symbols.
This commit is contained in:
committed by
Rich Felker
parent
6eb19505bc
commit
df7d0dfb9c
@ -1,7 +1,9 @@
|
||||
#include "pthread_impl.h"
|
||||
|
||||
void *pthread_getspecific(pthread_key_t k)
|
||||
static void *__pthread_getspecific(pthread_key_t k)
|
||||
{
|
||||
struct pthread *self = __pthread_self();
|
||||
return self->tsd[k];
|
||||
}
|
||||
|
||||
weak_alias(__pthread_getspecific, pthread_getspecific);
|
||||
|
Reference in New Issue
Block a user