aboutsummaryrefslogtreecommitdiff
path: root/linuxthreads/semaphore.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2001-04-10 21:46:48 +0000
committerUlrich Drepper <drepper@redhat.com>2001-04-10 21:46:48 +0000
commit58f46c794a3dc049ae8c53dab76d83ea23408479 (patch)
tree5695211b81ee73dc571857728e377b59a6938d92 /linuxthreads/semaphore.c
parentbf9d1166a06c7181e50d7d5c9a2cde665007ee1d (diff)
downloadglibc-58f46c794a3dc049ae8c53dab76d83ea23408479.tar
glibc-58f46c794a3dc049ae8c53dab76d83ea23408479.tar.gz
glibc-58f46c794a3dc049ae8c53dab76d83ea23408479.tar.bz2
glibc-58f46c794a3dc049ae8c53dab76d83ea23408479.zip
Update.
2001-04-10 Martin Schwidefsky <schwidefsky@de.ibm.com> * sysdeps/unix/sysv/linux/s390/s390-32/getcontext.S: Fix return value of getcontext. * sysdeps/unix/sysv/linux/s390/s390-64/getcontext.S: Likewise. * sysdeps/unix/sysv/linux/s390/s390-32/setcontext.S: Fix return value of setcontext. * sysdeps/unix/sysv/linux/s390/s390-64/setcontext.S: Likewise. * sysdeps/unix/sysv/linux/s390/swapcontext.c: Skip setcontext call by changing the saved context.
Diffstat (limited to 'linuxthreads/semaphore.c')
-rw-r--r--linuxthreads/semaphore.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/linuxthreads/semaphore.c b/linuxthreads/semaphore.c
index e5afce43eb..bb681b3621 100644
--- a/linuxthreads/semaphore.c
+++ b/linuxthreads/semaphore.c
@@ -85,7 +85,7 @@ int __new_sem_wait(sem_t * sem)
if (already_canceled) {
__pthread_set_own_extricate_if(self, 0);
- pthread_exit(PTHREAD_CANCELED);
+ __pthread_do_exit(PTHREAD_CANCELED, CURRENT_STACK_FRAME);
}
/* Wait for sem_post or cancellation, or fall through if already canceled */
@@ -111,7 +111,7 @@ int __new_sem_wait(sem_t * sem)
if (THREAD_GETMEM(self, p_woken_by_cancel)
&& THREAD_GETMEM(self, p_cancelstate) == PTHREAD_CANCEL_ENABLE) {
THREAD_SETMEM(self, p_woken_by_cancel, 0);
- pthread_exit(PTHREAD_CANCELED);
+ __pthread_do_exit(PTHREAD_CANCELED, CURRENT_STACK_FRAME);
}
/* We got the semaphore */
return 0;
@@ -245,7 +245,7 @@ int sem_timedwait(sem_t *sem, const struct timespec *abstime)
if (already_canceled) {
__pthread_set_own_extricate_if(self, 0);
- pthread_exit(PTHREAD_CANCELED);
+ __pthread_do_exit(PTHREAD_CANCELED, CURRENT_STACK_FRAME);
}
spurious_wakeup_count = 0;
@@ -289,7 +289,7 @@ int sem_timedwait(sem_t *sem, const struct timespec *abstime)
if (THREAD_GETMEM(self, p_woken_by_cancel)
&& THREAD_GETMEM(self, p_cancelstate) == PTHREAD_CANCEL_ENABLE) {
THREAD_SETMEM(self, p_woken_by_cancel, 0);
- pthread_exit(PTHREAD_CANCELED);
+ __pthread_do_exit(PTHREAD_CANCELED, CURRENT_STACK_FRAME);
}
/* We got the semaphore */
return 0;