From 230fe2a5a10f2bc128f354e3fb1b48536b1f143b Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Thu, 19 Sep 2013 14:40:08 -0700 Subject: Merge from gnulib. This incorporates the following changes: 2013-09-19 stdio: OS X port of putc_unlocked + extern inline 2013-09-19 signal: OS X port of sigaddset etc. + extern inline 2013-09-19 extern-inline: do not always suppress extern inline on OS X 2013-09-17 getgroups: statement without effect 2013-08-28 headers: check that _GL_INLINE_HEADER_BEGIN is defined --- lib/utimens.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'lib/utimens.c') diff --git a/lib/utimens.c b/lib/utimens.c index 013843d6da4..44a33c1d791 100644 --- a/lib/utimens.c +++ b/lib/utimens.c @@ -90,10 +90,12 @@ validate_timespec (struct timespec timespec[2]) assert (timespec); if ((timespec[0].tv_nsec != UTIME_NOW && timespec[0].tv_nsec != UTIME_OMIT - && (timespec[0].tv_nsec < 0 || 1000000000 <= timespec[0].tv_nsec)) + && ! (0 <= timespec[0].tv_nsec + && timespec[0].tv_nsec < TIMESPEC_RESOLUTION)) || (timespec[1].tv_nsec != UTIME_NOW && timespec[1].tv_nsec != UTIME_OMIT - && (timespec[1].tv_nsec < 0 || 1000000000 <= timespec[1].tv_nsec))) + && ! (0 <= timespec[1].tv_nsec + && timespec[1].tv_nsec < TIMESPEC_RESOLUTION))) { errno = EINVAL; return -1; -- cgit v1.2.1