[PATCH] time: Use CLOCK_REALTIME for time (BZ #30200)
Paul Eggert
eggert@cs.ucla.edu
Wed Mar 8 05:51:00 GMT 2023
On 2023-03-07 04:07, Florian Weimer via Libc-alpha wrote:
> Probably RESOLVED/MOVED because we get whatever time the kernel
> provides. It seems a deliberate kernel decision to me.
For my own information, is 'time' the only standard function that uses a
clock other than CLOCK_REALTIME and so can be out-of-sync with
timespec_get? What about gettimeofday, futimens with UTIME_NOW, or
timestamps set by modifying files?
My idea is to go through the apps I help maintain, and make sure that
they never call 'time' anywhere that it's important that a timestamp be
in sync with with the rest of the system, since Glibc 'time' is out of
sync in that way.
More information about the Libc-alpha
mailing list