diff options
Diffstat (limited to 'sysdeps/pthread')
-rw-r--r-- | sysdeps/pthread/timer_settime.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sysdeps/pthread/timer_settime.c b/sysdeps/pthread/timer_settime.c index 3d20495283..0fad4b1983 100644 --- a/sysdeps/pthread/timer_settime.c +++ b/sysdeps/pthread/timer_settime.c @@ -41,10 +41,8 @@ timer_settime (timer_t timerid, int flags, const struct itimerspec *value, goto bail; } - if (value->it_interval.tv_nsec < 0 - || value->it_interval.tv_nsec >= 1000000000 - || value->it_value.tv_nsec < 0 - || value->it_value.tv_nsec >= 1000000000) + if (! valid_nanoseconds (value->it_interval.tv_nsec) + || ! valid_nanoseconds (value->it_value.tv_nsec)) { __set_errno (EINVAL); goto bail; |