Apologies for a very late reply. On Fri, Sep 16, 2022 at 3:07 PM Miroslav Lichvar <[email protected]> wrote: > The 32-bit integer part of the NTP timestamp overflows in year 2036, > which starts the second NTP era.
> + /* Shift timestamps before 1970 to the second NTP era (2036-2106) */ > + if (lfp.int_partl < OFFSET_1900_1970) > + ret += (double)UINT_MAX + 1.0; Shouldn't this be 0xffffffff instead of UINT_MAX? What you are doing here is treating 0...OFFSET_1900_1970 as if there is a carry bit in int_partl, right? And int_partl is not unit_t. It's uint32_t. Thus you need to add (1<<32). _______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
