3 ms·
I think you're talking about struct timespec, I'm talking about time_t. I don't think "POSIX time" specifies behavior during leap-seconds for the functions tha
by amiga386 2y ago
I think you're talking about struct timespec, I'm talking about time_t.
I don't think "POSIX time" specifies behavior during leap-seconds for the functions that return timespecs (gettimeofday() [0] and clock_gettime(CLOCK_REALTIME) [1]), so any behaviour would be valid - including smearing or repeating nanoseconds?
[0] https://pubs.opengroup.org/onlinepubs/9699919799/functions/gettimeofday.html https://pubs.opengroup.org/onlinepubs/9699919799/functions/g...
[1] https://pubs.opengroup.org/onlinepubs/9699919799/functions/clock_gettime.html https://pubs.opengroup.org/onlinepubs/9699919799/functions/c...