summarylogtreecommitdiffstats
path: root/pthread_mutexattr_settype.patch
blob: f1918c6c40cb6bb9de011424db22a6c2f60b1900 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
diff --git a/src/fuse/mutex.c b/src/fuse/mutex.c
index beb6f93..f035ec8 100644
--- a/src/fuse/mutex.c
+++ b/src/fuse/mutex.c
@@ -35,16 +35,6 @@
 #endif
 #endif
 
-/**
- * This prototype is somehow missing in various Linux pthread
- * include files. But we need it and it seems to be available
- * on all pthread-systems so far. Odd.
- */
-#ifndef _MSC_VER
-extern int pthread_mutexattr_setkind_np (pthread_mutexattr_t * attr,
-                                         int kind);
-#endif
-
 
 /**
  * @brief Structure for MUTual EXclusion (Mutex).
@@ -67,23 +57,13 @@ GNUNET_mutex_create (int isRecursive)
   pthread_mutexattr_init (&attr);
   if (isRecursive)
     {
-#ifdef __linux__
-      GNUNET_assert (0 == pthread_mutexattr_setkind_np
-		     (&attr, PTHREAD_MUTEX_RECURSIVE_NP));
-#elif BSD || SOLARIS || OSX || WINDOWS
       GNUNET_assert (0 == pthread_mutexattr_settype
 		     (&attr, PTHREAD_MUTEX_RECURSIVE));
-#endif
     }
   else
     {
-#ifdef __linux__
-      GNUNET_assert (0 == pthread_mutexattr_setkind_np
-		     (&attr, PTHREAD_MUTEX_ERRORCHECK_NP));
-#else
       GNUNET_assert (0 == pthread_mutexattr_settype
 		     (&attr, PTHREAD_MUTEX_ERRORCHECK));
-#endif
     }
   mut = GNUNET_new (struct GNUNET_Mutex);
   GNUNET_assert (0 == pthread_mutex_init (&mut->pt, &attr));