Lines Matching full:error

51 	int error;  in mtx_init()  local
53 error = pthread_mutex_init(lock, NULL); in mtx_init()
54 PJDLOG_ASSERT(error == 0); in mtx_init()
59 int error; in mtx_destroy() local
61 error = pthread_mutex_destroy(lock); in mtx_destroy()
62 PJDLOG_ASSERT(error == 0); in mtx_destroy()
67 int error; in mtx_lock() local
69 error = pthread_mutex_lock(lock); in mtx_lock()
70 PJDLOG_ASSERT(error == 0); in mtx_lock()
75 int error; in mtx_trylock() local
77 error = pthread_mutex_trylock(lock); in mtx_trylock()
78 PJDLOG_ASSERT(error == 0 || error == EBUSY); in mtx_trylock()
79 return (error == 0); in mtx_trylock()
84 int error; in mtx_unlock() local
86 error = pthread_mutex_unlock(lock); in mtx_unlock()
87 PJDLOG_ASSERT(error == 0); in mtx_unlock()
99 int error; in rw_init() local
101 error = pthread_rwlock_init(lock, NULL); in rw_init()
102 PJDLOG_ASSERT(error == 0); in rw_init()
107 int error; in rw_destroy() local
109 error = pthread_rwlock_destroy(lock); in rw_destroy()
110 PJDLOG_ASSERT(error == 0); in rw_destroy()
115 int error; in rw_rlock() local
117 error = pthread_rwlock_rdlock(lock); in rw_rlock()
118 PJDLOG_ASSERT(error == 0); in rw_rlock()
123 int error; in rw_wlock() local
125 error = pthread_rwlock_wrlock(lock); in rw_wlock()
126 PJDLOG_ASSERT(error == 0); in rw_wlock()
131 int error; in rw_unlock() local
133 error = pthread_rwlock_unlock(lock); in rw_unlock()
134 PJDLOG_ASSERT(error == 0); in rw_unlock()
141 int error; in cv_init() local
143 error = pthread_condattr_init(&attr); in cv_init()
144 PJDLOG_ASSERT(error == 0); in cv_init()
146 error = pthread_condattr_setclock(&attr, CLOCK_MONOTONIC); in cv_init()
147 PJDLOG_ASSERT(error == 0); in cv_init()
149 error = pthread_cond_init(cv, &attr); in cv_init()
150 PJDLOG_ASSERT(error == 0); in cv_init()
151 error = pthread_condattr_destroy(&attr); in cv_init()
152 PJDLOG_ASSERT(error == 0); in cv_init()
157 int error; in cv_wait() local
159 error = pthread_cond_wait(cv, lock); in cv_wait()
160 PJDLOG_ASSERT(error == 0); in cv_wait()
166 int error; in cv_timedwait() local
174 error = clock_gettime(CLOCK_MONOTONIC, &ts); in cv_timedwait()
175 PJDLOG_ASSERT(error == 0); in cv_timedwait()
177 error = pthread_cond_timedwait(cv, lock, &ts); in cv_timedwait()
181 error = pthread_cond_timedwait_relative_np(cv, lock, &ts); in cv_timedwait()
183 #error Neither pthread_condattr_setclock nor pthread_cond_timedwait_relative_np is available. in cv_timedwait()
185 PJDLOG_ASSERT(error == 0 || error == ETIMEDOUT); in cv_timedwait()
186 return (error == ETIMEDOUT); in cv_timedwait()
191 int error; in cv_signal() local
193 error = pthread_cond_signal(cv); in cv_signal()
194 PJDLOG_ASSERT(error == 0); in cv_signal()
199 int error; in cv_broadcast() local
201 error = pthread_cond_broadcast(cv); in cv_broadcast()
202 PJDLOG_ASSERT(error == 0); in cv_broadcast()