]> git.meshlink.io Git - meshlink/commitdiff
When resetting timers that use CLOCK_MONOTONIC, use a negative value.
authorGuus Sliepen <guus@meshlink.io>
Sat, 11 Apr 2020 15:43:18 +0000 (17:43 +0200)
committerGuus Sliepen <guus@meshlink.io>
Sat, 11 Apr 2020 15:45:03 +0000 (17:45 +0200)
CLOCK_MONOTONIC might be implemented as the time since the CPU booted, so
if MeshLink starts soon after booting, setting timers to "0" might not
actually be far enough in the past to trigger a timeout.

This has almost no effect in practice, since most timeouts are a minute or
less, but it might affect running tests in virtual machines.


No differences found