summaryrefslogtreecommitdiff
path: root/lib/libpthread/thread/thr_cond.c
diff options
context:
space:
mode:
authorDaniel Eischen <deischen@FreeBSD.org>2000-03-15 13:59:27 +0000
committerDaniel Eischen <deischen@FreeBSD.org>2000-03-15 13:59:27 +0000
commit1d013a86edb866de00bf57761c845388c8d9a467 (patch)
tree935feb03e56c674b055ccf5f23861c18e476211a /lib/libpthread/thread/thr_cond.c
parent8d548e1f88b83ea07e628bc6ddb7144ee8379bcd (diff)
Notes
Diffstat (limited to 'lib/libpthread/thread/thr_cond.c')
-rw-r--r--lib/libpthread/thread/thr_cond.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/lib/libpthread/thread/thr_cond.c b/lib/libpthread/thread/thr_cond.c
index d23660788fc9..78ee042f8fd1 100644
--- a/lib/libpthread/thread/thr_cond.c
+++ b/lib/libpthread/thread/thr_cond.c
@@ -282,8 +282,11 @@ pthread_cond_wait(pthread_cond_t * cond, pthread_mutex_t * mutex)
break;
}
- if (interrupted != 0 && _thread_run->continuation != NULL)
- _thread_run->continuation((void *) _thread_run);
+ if (interrupted != 0) {
+ if (_thread_run->continuation != NULL)
+ _thread_run->continuation((void *) _thread_run);
+ rval = EINTR;
+ }
_thread_leave_cancellation_point();
}
@@ -449,8 +452,11 @@ pthread_cond_timedwait(pthread_cond_t * cond, pthread_mutex_t * mutex,
break;
}
- if (interrupted != 0 && _thread_run->continuation != NULL)
- _thread_run->continuation((void *) _thread_run);
+ if (interrupted != 0) {
+ if (_thread_run->continuation != NULL)
+ _thread_run->continuation((void *) _thread_run);
+ rval = EINTR;
+ }
_thread_leave_cancellation_point();
}