about summary refs log tree commit diff
path: root/linuxthreads/sysdeps/pthread/timer_getoverr.c
diff options
context:
space:
mode:
Diffstat (limited to 'linuxthreads/sysdeps/pthread/timer_getoverr.c')
-rw-r--r--linuxthreads/sysdeps/pthread/timer_getoverr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/linuxthreads/sysdeps/pthread/timer_getoverr.c b/linuxthreads/sysdeps/pthread/timer_getoverr.c
index 8630f57829..520458c712 100644
--- a/linuxthreads/sysdeps/pthread/timer_getoverr.c
+++ b/linuxthreads/sysdeps/pthread/timer_getoverr.c
@@ -34,8 +34,8 @@ timer_getoverrun (timerid)
 
   pthread_mutex_lock (&__timer_mutex);
 
-  if ((timer = timer_id2ptr (timerid)) == NULL || !timer->inuse)
-    errno = EINVAL;
+  if (! timer_valid (timer = timer_id2ptr (timerid)))
+    __set_errno (EINVAL);
   else
     retval = 0; /* TODO: overrun counting not supported */