diff --git a/lib/glthread/cond.c b/lib/glthread/cond.c index c35272e..087369f 100644 --- a/lib/glthread/cond.c +++ b/lib/glthread/cond.c @@ -102,6 +102,8 @@ glthread_cond_init_func (gl_cond_t *cond) int glthread_cond_wait_func (gl_cond_t *cond, gl_lock_t *lock) { + int ret; + if (!cond->guard.done) { if (InterlockedIncrement (&cond->guard.started) == 0) @@ -189,6 +191,7 @@ glthread_cond_wait_func (gl_cond_t *cond, gl_lock_t *lock) int glthread_cond_timedwait_func (gl_cond_t *cond, gl_lock_t *lock, struct timespec *abstime) { + int ret; struct timeval currtime; gettimeofday (&currtime, NULL); diff --git a/tests/test-poll.c b/tests/test-poll.c index 3b4ab35..64dec2c 100644 --- a/tests/test-poll.c +++ b/tests/test-poll.c @@ -22,6 +22,7 @@ #include #include #include +#include #include #include #include diff --git a/tests/test-select.c b/tests/test-select.c index 50f7559..6de3d0d 100644 --- a/tests/test-select.c +++ b/tests/test-select.c @@ -24,6 +24,7 @@ #include #include #include +#include #include #include #include