1 /* 2 * Copyright 2009, Ingo Weinhold, ingo_weinhold@gmx.de. 3 * Distributed under the terms of the MIT License. 4 */ 5 6 #include <pthread.h> 7 8 #include "posix_error_mapper.h" 9 10 11 WRAPPER_FUNCTION(int, pthread_cond_destroy, (pthread_cond_t *cond), 12 return B_TO_POSITIVE_ERROR(sReal_pthread_cond_destroy(cond)); 13 ) 14 15 16 WRAPPER_FUNCTION(int, pthread_cond_init, (pthread_cond_t *cond, 17 const pthread_condattr_t *attr), 18 return B_TO_POSITIVE_ERROR(sReal_pthread_cond_init(cond, attr)); 19 ) 20 21 22 WRAPPER_FUNCTION(int, pthread_cond_broadcast, (pthread_cond_t *cond), 23 return B_TO_POSITIVE_ERROR(sReal_pthread_cond_broadcast(cond)); 24 ) 25 26 27 WRAPPER_FUNCTION(int, pthread_cond_signal, (pthread_cond_t *cond), 28 return B_TO_POSITIVE_ERROR(sReal_pthread_cond_signal(cond)); 29 ) 30 31 32 WRAPPER_FUNCTION(int, pthread_cond_timedwait, (pthread_cond_t *cond, 33 pthread_mutex_t *mutex, const struct timespec *abstime), 34 return B_TO_POSITIVE_ERROR(sReal_pthread_cond_timedwait(cond, mutex, 35 abstime)); 36 ) 37 38 39 WRAPPER_FUNCTION(int, pthread_cond_wait, (pthread_cond_t *cond, 40 pthread_mutex_t *mutex), 41 return B_TO_POSITIVE_ERROR(sReal_pthread_cond_wait(cond, mutex)); 42 ) 43 44