On 12/27/2010 06:20 AM, Bruno Haible wrote: > If I remove the "&& !HAVE_WORKING_UTIMES" from the condition, the three > tests pass, except for a small part with symlinks that is skipped:
Thanks for trying it out, and for going the extra mile and fixing that bug. I installed this: >From dd4243aafa3956f2b1bc698a2fb6a77561f88077 Mon Sep 17 00:00:00 2001 From: Paul Eggert <egg...@cs.ucla.edu> Date: Mon, 27 Dec 2010 11:01:57 -0800 Subject: [PATCH] utimens: work around glibc rounding bug on more platforms * lib/utimens.c (fdutimens): Work around rounding bug even if HAVE_WORKING_UTIMES. Reported for Linux 2.4.21 by Bruno Haible in <http://lists.gnu.org/archive/html/bug-gnulib/2010-12/msg00298.html>. --- ChangeLog | 7 +++++++ lib/utimens.c | 2 +- 2 files changed, 8 insertions(+), 1 deletions(-) diff --git a/ChangeLog b/ChangeLog index dc5dc40..57b2bc3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2010-12-27 Paul Eggert <egg...@cs.ucla.edu> + + utimens: work around glibc rounding bug on more platforms + * lib/utimens.c (fdutimens): Work around rounding bug even if + HAVE_WORKING_UTIMES. Reported for Linux 2.4.21 by Bruno Haible in + <http://lists.gnu.org/archive/html/bug-gnulib/2010-12/msg00298.html>. + 2010-12-27 Bruno Haible <br...@clisp.org> select tests: Improve comments. diff --git a/lib/utimens.c b/lib/utimens.c index 99b2290..af9acaa 100644 --- a/lib/utimens.c +++ b/lib/utimens.c @@ -338,7 +338,7 @@ fdutimens (int fd, char const *file, struct timespec const timespec[2]) # endif if (futimes (fd, t) == 0) { -# if __linux__ && __GLIBC__ && ! HAVE_WORKING_UTIMES +# if __linux__ && __GLIBC__ /* Work around a longstanding glibc bug, still present as of 2010-12-27. On older Linux kernels that lack both utimensat and utimes, glibc's futimes rounds instead of -- 1.7.2