summaryrefslogtreecommitdiff
path: root/libpthread/nptl/sysdeps/pthread
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@uclibc-ng.org>2016-11-10 02:26:09 +0100
committerWaldemar Brodkorb <wbx@uclibc-ng.org>2016-11-10 02:26:09 +0100
commita9a2380cf01cdae519fdaf8ab021d486c8917e43 (patch)
tree09c2d148b17bf7b6fcdb2d32be7d763db5b25c2a /libpthread/nptl/sysdeps/pthread
parentb8fcdddcbb192fc367ff04bbd753b9deb69b09f3 (diff)
nptl: add pthread_getname_np/pthread_setname_np from GNU libc
These functions are used by firefox for example. Tested with running firefox on x86 system.
Diffstat (limited to 'libpthread/nptl/sysdeps/pthread')
-rw-r--r--libpthread/nptl/sysdeps/pthread/pthread.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/libpthread/nptl/sysdeps/pthread/pthread.h b/libpthread/nptl/sysdeps/pthread/pthread.h
index 4103a06ad..b2897b3f2 100644
--- a/libpthread/nptl/sysdeps/pthread/pthread.h
+++ b/libpthread/nptl/sysdeps/pthread/pthread.h
@@ -428,6 +428,16 @@ extern int pthread_getschedparam (pthread_t __target_thread,
extern int pthread_setschedprio (pthread_t __target_thread, int __prio)
__THROW;
+#ifdef __USE_GNU
+/* Get thread name visible in the kernel and its interfaces. */
+extern int pthread_getname_np (pthread_t __target_thread, char *__buf,
+ size_t __buflen)
+ __THROW __nonnull ((2));
+
+/* Set thread name visible in the kernel and its interfaces. */
+extern int pthread_setname_np (pthread_t __target_thread, const char *__name)
+ __THROW __nonnull ((2));
+#endif
#if defined __USE_UNIX98 && defined __UCLIBC_SUSV4_LEGACY__
/* Determine level of concurrency. */