From 559382738799bf3bef8d81c2091bd713ec8c1c9e Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Thu, 8 Jun 2000 20:38:08 +0000 Subject: Update. * sysdeps/pthread/posix-timer.h (struct timer_node): Add creator_pid. * sysdeps/pthread/timer_create.c: Fill in creator_pid. * sysdeps/pthread/timer_routines.c (thread_expire_timer): Send signal with sigqueueinfo is this system call is available. * sysdeps/pthread/timer_create.c (timer_create): Allow CLOCK_CPUTIME if _POSIX_CPUTIME is defined. --- linuxthreads/sysdeps/pthread/timer_create.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'linuxthreads/sysdeps/pthread/timer_create.c') diff --git a/linuxthreads/sysdeps/pthread/timer_create.c b/linuxthreads/sysdeps/pthread/timer_create.c index 36823e83b6..84e5cfed2f 100644 --- a/linuxthreads/sysdeps/pthread/timer_create.c +++ b/linuxthreads/sysdeps/pthread/timer_create.c @@ -36,7 +36,11 @@ timer_create (clock_id, evp, timerid) struct timer_node *newtimer = NULL; struct thread_node *thread = NULL; - if (clock_id != CLOCK_REALTIME) + if (clock_id != CLOCK_REALTIME +#ifdef _POSIX_CPUTIME + && clock_id != CLOCK_CPUTIME +#endif + ) { errno = EINVAL; return -1; @@ -70,6 +74,7 @@ timer_create (clock_id, evp, timerid) } newtimer->event.sigev_notify_attributes = &newtimer->attr; + newtimer->creator_pid = getpid (); switch (__builtin_expect (newtimer->event.sigev_notify, SIGEV_SIGNAL)) { -- cgit v1.2.3-70-g09d2