mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-06 13:29:56 -05:00
unify static TLS support, make use of gcc __thread attribute if available
git-svn-id: file:///home/lennart/svn/public/pulseaudio/branches/lennart@1797 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
3d122d0fee
commit
9b0ab39b1c
7 changed files with 59 additions and 32 deletions
|
|
@ -324,14 +324,14 @@ static void libtool_unlock(void) {
|
|||
pa_mutex_unlock(libtool_mutex);
|
||||
}
|
||||
|
||||
PA_STATIC_TLS_DECLARE(libtool_tls, NULL);
|
||||
PA_STATIC_TLS_DECLARE_NO_FREE(libtool_tls);
|
||||
|
||||
static void libtool_set_error(const char * error) {
|
||||
pa_tls_set(PA_STATIC_TLS_GET(libtool_tls), (char*) error);
|
||||
PA_STATIC_TLS_SET(libtool_tls, (char*) error);
|
||||
}
|
||||
|
||||
static const char *libtool_get_error(void) {
|
||||
return pa_tls_get(PA_STATIC_TLS_GET(libtool_tls));
|
||||
return PA_STATIC_TLS_GET(libtool_tls);
|
||||
}
|
||||
|
||||
static void libtool_init(void) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue