On Mon, Mar 23, 2015 at 10:42 AM, Alexey Suslikov
wrote:
> Brent Cook gmail.com> writes:
>
>> + T4 += (uint64_t)tv.tv_sec + JAN_1970 + 1.0e-6 *
> tv.tv_usec;
>
>
>
>> + return ((uint64_t)tv.tv_sec + JAN_1970 + 1.0e-6 * tv.tv_usec);
>
>
>
> Can gettime_from_timeval be use
Brent Cook gmail.com> writes:
> + T4 += (uint64_t)tv.tv_sec + JAN_1970 + 1.0e-6 *
tv.tv_usec;
> + return ((uint64_t)tv.tv_sec + JAN_1970 + 1.0e-6 * tv.tv_usec);
Can gettime_from_timeval be used over the code instead of repeating
same chunk?
T4 += gettime_from_timev
This came up in the OpenNTPD issue tracker:
https://github.com/openntpd-portable/openntpd-openbsd/pull/4
The issue is an overflow when calculating time offsets with a 32-bit
time_t in early 2036. The main reason to fix it in now, in 2015, is that
OpenNTPD fails to adjust time if such a system simp