mirror of https://github.com/mkerrisk/man-pages
gettimeofday.2: gettimeofday() is affected by discontinuous jumps in the system time
Advise reader to use clock_gettime(2), if they need a monotonically increasing time source. Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
parent
fb6fc61227
commit
5f04b9486b
|
@ -170,6 +170,14 @@ as obsolete, recommending the use of
|
|||
.BR clock_gettime (2)
|
||||
instead.
|
||||
.SH NOTES
|
||||
The time returned by
|
||||
.BR gettimeofday (2)
|
||||
.I is
|
||||
affected by discontinuous jumps in the system time
|
||||
(e.g., if the system administrator manually changes the system time).
|
||||
If you need a monotonically increasing clock, see
|
||||
.BR clock_gettime (2).
|
||||
|
||||
Macros for operating on
|
||||
.I timeval
|
||||
structures are described in
|
||||
|
|
Loading…
Reference in New Issue