From d4f59be550779a187578dac62baf0161eb09aa64 Mon Sep 17 00:00:00 2001 From: mtm Date: Tue, 30 Dec 2003 08:34:57 +0000 Subject: Make it possible for the library to specify a timeout value when waiting on a locked mutex. This involves passing a struct timespec from the pthread mutex locking interfaces all the way down to the function that suspends the thread until the mutex is released. The timeout is assumed to be an absolute time (i.e. not relative to the current time). Also, in _thread_suspend() make the passed in timespec const. --- lib/libthr/thread/thr_kern.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/libthr/thread/thr_kern.c') diff --git a/lib/libthr/thread/thr_kern.c b/lib/libthr/thread/thr_kern.c index 516c570..3584246 100644 --- a/lib/libthr/thread/thr_kern.c +++ b/lib/libthr/thread/thr_kern.c @@ -117,7 +117,7 @@ _thread_sigunblock() } int -_thread_suspend(pthread_t pthread, struct timespec *abstime) +_thread_suspend(pthread_t pthread, const struct timespec *abstime) { struct timespec remaining; struct timespec *ts; -- cgit v1.1