aboutsummaryrefslogtreecommitdiff
path: root/gcc/gthr-solaris.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/gthr-solaris.h')
-rw-r--r--gcc/gthr-solaris.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/gcc/gthr-solaris.h b/gcc/gthr-solaris.h
index 33ddf7a..b44a4de 100644
--- a/gcc/gthr-solaris.h
+++ b/gcc/gthr-solaris.h
@@ -44,9 +44,11 @@ typedef struct {
int once;
} __gthread_once_t;
typedef mutex_t __gthread_mutex_t;
+typedef mutex_t __gthread_recursive_mutex_t;
#define __GTHREAD_ONCE_INIT { DEFAULTMUTEX, 0 }
#define __GTHREAD_MUTEX_INIT DEFAULTMUTEX
+#define __GTHREAD_RECURSIVE_MUTEX_INIT RECURSIVE_ERRORCHECKMUTEX
#if SUPPORTS_WEAK && GTHREAD_USE_WEAK
@@ -466,6 +468,24 @@ __gthread_mutex_unlock (__gthread_mutex_t *mutex)
return 0;
}
+static inline int
+__gthread_recursive_mutex_lock (__gthread_recursive_mutex_t *mutex)
+{
+ return __gthread_mutex_lock (mutex);
+}
+
+static inline int
+__gthread_recursive_mutex_trylock (__gthread_recursive_mutex_t *mutex)
+{
+ return __gthread_mutex_trylock (mutex);
+}
+
+static inline int
+__gthread_recursive_mutex_unlock (__gthread_recursive_mutex_t *mutex)
+{
+ return __gthread_mutex_unlock (mutex);
+}
+
#endif /* _LIBOBJC */
#endif /* ! GCC_GTHR_SOLARIS_H */