Advertisement
Guest User

Untitled

a guest
Jun 26th, 2017
53
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.68 KB | None | 0 0
  1. diff -up ntp-dev-4.2.7p79/ntpd/ntp_loopfilter.c.orig ntp-dev-4.2.7p79/ntpd/ntp_loopfilter.c
  2. --- ntp-dev-4.2.7p79/ntpd/ntp_loopfilter.c.orig 2010-11-08 10:31:04.849887940 +0100
  3. +++ ntp-dev-4.2.7p79/ntpd/ntp_loopfilter.c 2010-11-08 17:50:45.741056405 +0100
  4. @@ -729,6 +729,12 @@ adj_host_clock(
  5. adjustment = clock_offset / (CLOCK_PLL * ULOGTOD(1));
  6. else
  7. adjustment = clock_offset / (CLOCK_PLL * ULOGTOD(sys_poll));
  8. +
  9. + if (adjustment + drift_comp > 500e-6)
  10. + adjustment = 500e-6 - drift_comp;
  11. + else if (adjustment + drift_comp < -500e-6)
  12. + adjustment = -500e-6 - drift_comp;
  13. +
  14. clock_offset -= adjustment;
  15. adj_systime(adjustment + drift_comp);
  16. #endif /* LOCKCLOCK */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement