about summary refs log tree commit diff
path: root/sysdeps/generic/bits/libc-tsd.h
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/generic/bits/libc-tsd.h')
-rw-r--r--sysdeps/generic/bits/libc-tsd.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/sysdeps/generic/bits/libc-tsd.h b/sysdeps/generic/bits/libc-tsd.h
index fc17be108e..3c77e1519f 100644
--- a/sysdeps/generic/bits/libc-tsd.h
+++ b/sysdeps/generic/bits/libc-tsd.h
@@ -51,11 +51,14 @@
 
 #if USE_TLS && HAVE___THREAD
 # define __libc_tsd_define(CLASS, KEY)	CLASS __thread void *__libc_tsd_##KEY;
+
+# define __libc_tsd_get(KEY)		(__libc_tsd_##KEY)
+# define __libc_tsd_set(KEY, VALUE)	(__libc_tsd_##KEY = (VALUE))
 #else
-# define __libc_tsd_define(CLASS, KEY)	CLASS void *__libc_tsd_##KEY;
-#endif
+# define __libc_tsd_define(CLASS, KEY)	CLASS void *__libc_tsd_##KEY##_data;
 
-#define __libc_tsd_get(KEY)		(__libc_tsd_##KEY)
-#define __libc_tsd_set(KEY, VALUE)	(__libc_tsd_##KEY = (VALUE))
+# define __libc_tsd_get(KEY)		(__libc_tsd_##KEY##_data)
+# define __libc_tsd_set(KEY, VALUE)	(__libc_tsd_##KEY##_data = (VALUE))
+#endif
 
 #endif	/* bits/libc-tsd.h */