about summary refs log tree commit diff
path: root/sysdeps/unix/sysv/linux/fatal-prepare.h
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/unix/sysv/linux/fatal-prepare.h')
-rw-r--r--sysdeps/unix/sysv/linux/fatal-prepare.h19
1 files changed, 3 insertions, 16 deletions
diff --git a/sysdeps/unix/sysv/linux/fatal-prepare.h b/sysdeps/unix/sysv/linux/fatal-prepare.h
index 45d88ce911..2a89567299 100644
--- a/sysdeps/unix/sysv/linux/fatal-prepare.h
+++ b/sysdeps/unix/sysv/linux/fatal-prepare.h
@@ -19,19 +19,6 @@
 
 /* We have to completely disable cancellation.  assert() must not be a
    cancellation point but the implementation uses write() etc.  */
-#ifdef SHARED
-# include <pthread-functions.h>
-# define FATAL_PREPARE \
-  {									      \
-    if (__libc_pthread_functions_init)					      \
-      PTHFCT_CALL (ptr_pthread_setcancelstate, (PTHREAD_CANCEL_DISABLE,	      \
-						NULL));			      \
-  }
-#else
-# pragma weak pthread_setcancelstate
-# define FATAL_PREPARE \
-  {									      \
-    if (pthread_setcancelstate != NULL)					      \
-      pthread_setcancelstate (PTHREAD_CANCEL_DISABLE, NULL);		      \
-  }
-#endif
+#define FATAL_PREPARE \
+  __libc_ptf_call (__pthread_setcancelstate, \
+		   (PTHREAD_CANCEL_DISABLE, NULL), 0)