[Git][NTPsec/ntpsec][master] Prevent a warning in an unusual configuration case.

Eric S. Raymond gitlab at mg.gitlab.com
Sun Nov 13 20:54:27 UTC 2016


Eric S. Raymond pushed to branch master at NTPsec / ntpsec


Commits:
2e1ddd92 by Eric S. Raymond at 2016-11-13T15:54:19-05:00
Prevent a warning in an unusual configuration case.

- - - - -


1 changed file:

- ntpd/ntp_loopfilter.c


Changes:

=====================================
ntpd/ntp_loopfilter.c
=====================================
--- a/ntpd/ntp_loopfilter.c
+++ b/ntpd/ntp_loopfilter.c
@@ -121,9 +121,9 @@ double	drift_comp;		/* frequency (s/s) */
 static double init_drift_comp; /* initial frequency (PPM) */
 double	clock_stability;	/* frequency stability (wander) (s/s) */
 u_int	sys_tai;		/* TAI offset from UTC */
-#if !defined(ENABLE_LOCKCLOCK) || defined(HAVE_KERNEL_PLL)
+#if !defined(ENABLE_LOCKCLOCK) && defined(HAVE_KERNEL_PLL)
 static bool loop_started;	/* true after LOOP_DRIFTINIT */
-#endif /* !ENABLE_LOCKCLOCK || HAVE_KERNEL_PLL */
+#endif /* !ENABLE_LOCKCLOCK && HAVE_KERNEL_PLL */
 #ifndef ENABLE_LOCKCLOCK
 static void rstclock (int, double); /* transition function */
 static double direct_freq(double); /* direct set frequency */
@@ -1276,8 +1276,10 @@ loop_config(
 			rstclock(EVNT_FSET, 0);
 		else
 			rstclock(EVNT_NSET, 0);
+#ifndef HAVE_KERNEL_PLL
 		loop_started = true;
-#endif /* ENABLE_LOCKCLOCK */
+#endif /* !HAVE_KERNEL_PLL */
+#endif /* !ENABLE_LOCKCLOCK */
 		break;
 
 	case LOOP_KERN_CLEAR:



View it on GitLab: https://gitlab.com/NTPsec/ntpsec/commit/2e1ddd9244c1c4dbfede798155c813bec67cccfe
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ntpsec.org/pipermail/vc/attachments/20161113/fc2c618f/attachment.html>


More information about the vc mailing list