summaryrefslogtreecommitdiff
path: root/nptl/pthread_self.c
diff options
context:
space:
mode:
Diffstat (limited to 'nptl/pthread_self.c')
-rw-r--r--nptl/pthread_self.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/nptl/pthread_self.c b/nptl/pthread_self.c
index c94267d31f..3c597beac5 100644
--- a/nptl/pthread_self.c
+++ b/nptl/pthread_self.c
@@ -16,13 +16,17 @@
License along with the GNU C Library; if not, see
<http://www.gnu.org/licenses/>. */
-#include "pthreadP.h"
+#include <pthreadP.h>
#include <tls.h>
pthread_t
__pthread_self (void)
{
+#ifndef PTHREAD_T_IS_TID
return (pthread_t) THREAD_SELF;
+#else
+ return THREAD_GETMEM (THREAD_SELF, tid);
+#endif
}
strong_alias (__pthread_self, pthread_self)