Yo [email protected]! On Tue, 19 Jul 2016 23:18:18 -0700 Hal Murray <[email protected]>, [email protected] wrote:
> [email protected] said: > >> In general there's a common belief that a leap second can only > >> occur at the end of June or December. This is false. Don't ever > >> hardcode this assumption. > > > NTP Classic thinks otherwise: > > http://bugs.ntp.org/show_bug.cgi?id=3D1090 > > If you read the fine print in that bug, you will see that it's a work > around for a bug in the HP firmware that is the core of this > discussion. Yes, I know the problem being solved. Like today, the leap second being broadcast sooner than ntpd expects, so it picks the wrong month. > I don't think there is anything in the core of ntpd that restricts > leap seconds to Jun/Dec. If there was, it would have filtered out > the above problem. How about this: ntpd/refclock_hpgps.c, line 544: /* See http://bugs.ntp.org/1090 * Ignore leap announcements unless June or December. * Better would be to use :GPSTime? to find the month, * but that seems too likely to introduce other bugs. */ case '+': if ((month==6) || (month==12)) > Things get interesting if you are shipping code today that will last > for 10 or 20 years. My HP Z3801A has software dates from 1995 so 20 > years isn't unreasonable. Of course, they were retired from > commercial use a long time ago, so maybe it's OK if the firmware has > bugs. 20 years? My house is 40 years old. In an IoT world people would like to not throw away capital equipment every decade. But i'm prolly spitting into the wind... > I don't know any software projects that handle this sort of thing > cleanly. (My exposure is limited.) gpsd filters out all but June and December. So sort of cleanly, but clearly work needed. I notice ntpd also filters out leap warnings for the first short bit of the month. That might be worth doing too. I'm sure something else will crop up before 2017. If a giant asteroid hits earth, and we need a negative leap second in March, there will be a lot of urgent patching to do. RGDS GARY --------------------------------------------------------------------------- Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703 [email protected] Tel:+1 541 382 8588
pgpOOCjNb7TtZ.pgp
Description: OpenPGP digital signature
_______________________________________________ time-nuts mailing list -- [email protected] To unsubscribe, go to https://www.febo.com/cgi-bin/mailman/listinfo/time-nuts and follow the instructions there.
