From: Harlan Stenn Date: Wed, 31 Mar 2010 08:11:55 +0000 (-0400) Subject: [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4 X-Git-Tag: NTP_4_2_6P1_RC6~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=292972b2f47fa3a3fbf6ee820456f3e4cb3c8752;p=thirdparty%2Fntp.git [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4 bk: 4bb303cbX5SkdQd-X08kNf9XTZjJIQ --- diff --git a/ChangeLog b/ChangeLog index 27cd1d595..1152967dc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,6 @@ --- +* [Bug 1514] Typo in ntp_proto.c: fabs(foo < .4) should be fabs(foo) < .4. * [Bug 1464] synchronization source wrong for refclocks ARCRON_MSF (27) and SHM (28). * Correct Windows port's refclock_open() to return 0 on failure not -1. diff --git a/ntpd/ntp_proto.c b/ntpd/ntp_proto.c index db5e04d5c..367cc5ead 100644 --- a/ntpd/ntp_proto.c +++ b/ntpd/ntp_proto.c @@ -2677,7 +2677,7 @@ clock_select(void) * if there is a prefer peer or there are no survivors and none * are required. */ - if (typepps != NULL && fabs(sys_offset < 0.4) && + if (typepps != NULL && fabs(sys_offset) < 0.4 && (typepps->refclktype != REFCLK_ATOM_PPS || (typepps->refclktype == REFCLK_ATOM_PPS && (sys_prefer != NULL || (typesystem == NULL && sys_minsane == 0))))) {