31 lines
731 B
Diff
31 lines
731 B
Diff
musl defines gettid(), current glibc is >2.30
|
|
|
|
--- a/src/procattr.c
|
|
+++ b/src/procattr.c
|
|
@@ -22,25 +22,6 @@
|
|
static int destructor_key_initialized = 0;
|
|
static __thread char destructor_initialized;
|
|
|
|
-/* Bionic and glibc >= 2.30 declare gettid() system call wrapper in unistd.h and
|
|
- * has a definition for it */
|
|
-#ifdef __BIONIC__
|
|
- #define OVERRIDE_GETTID 0
|
|
-#elif !defined(__GLIBC_PREREQ)
|
|
- #define OVERRIDE_GETTID 1
|
|
-#elif !__GLIBC_PREREQ(2,30)
|
|
- #define OVERRIDE_GETTID 1
|
|
-#else
|
|
- #define OVERRIDE_GETTID 0
|
|
-#endif
|
|
-
|
|
-#if OVERRIDE_GETTID
|
|
-static pid_t gettid(void)
|
|
-{
|
|
- return syscall(__NR_gettid);
|
|
-}
|
|
-#endif
|
|
-
|
|
static void procattr_thread_destructor(void __attribute__((unused)) *unused)
|
|
{
|
|
if (prev_current != UNSET)
|