From: Harlan Stenn Date: Wed, 20 Nov 2013 08:56:38 +0000 (-0500) Subject: [Bug 2326] Improve stale leapsecond notifications X-Git-Tag: NTP_4_2_7P397~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=893063173457c962c5a063b24317bb617af28bf5;p=thirdparty%2Fntp.git [Bug 2326] Improve stale leapsecond notifications bk: 528c7946TCmhw6ODDKFhE21o7jrtDg --- diff --git a/ChangeLog b/ChangeLog index 8568bd2aa..24edbaf58 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,4 @@ +* [Bug 2326] More leapsecond file notification cleanup. (4.2.7p396) 2013/11/19 Released by Harlan Stenn * [Bug 2326] Improve stale leapsecond notifications. (4.2.7p395) 2013/11/12 Released by Harlan Stenn diff --git a/ntpd/ntp_io.c b/ntpd/ntp_io.c index 4ec67c8d8..cd4d871cb 100644 --- a/ntpd/ntp_io.c +++ b/ntpd/ntp_io.c @@ -3738,8 +3738,14 @@ input_handler( /* We're done... */ ih_return: if (check_leapfile < time(NULL)) { + int rc; + check_leapfile += CHECK_LEAP_EVERY; - (void)check_leap_file(); + rc = check_leap_file(); + + if (rc < 31) + msyslog(LOG_DEBUG, + "input_handler: check_leap_file() returned %d.' time!", rc); } return; } diff --git a/ntpd/ntp_timer.c b/ntpd/ntp_timer.c index 35562bc37..ee2575705 100644 --- a/ntpd/ntp_timer.c +++ b/ntpd/ntp_timer.c @@ -436,13 +436,12 @@ timer(void) report_event(EVNT_LEAPVAL, NULL, NULL); if (leap_warn_log == FALSE) { msyslog(LOG_WARNING, - "leapseconds data file has expire!."); + "timer: leapseconds data file has expired!"); leap_warn_log = TRUE; } } else if (clf < 31) { msyslog(LOG_WARNING, - "leapseconds data file will expire in about %d days' time!", clf); - /* squawk that leapfile will expire */ + "timer: leapseconds data file will expire in about %d days' time!", clf); } } else leap_warn_log = FALSE;