[Git][NTPsec/ntpsec][master] 4 commits: Remove "cohort" keyword and unused variable.
Hal Murray
gitlab at mg.gitlab.com
Fri Jan 20 01:03:12 UTC 2017
Hal Murray pushed to branch master at NTPsec / ntpsec
Commits:
87366dbe by Hal Murray at 2017-01-19T16:18:40-08:00
Remove "cohort" keyword and unused variable.
It was leftover from multicast.
- - - - -
78671957 by Hal Murray at 2017-01-19T16:18:40-08:00
Squash warning from OpenBSD
- - - - -
ae9bdc0e by Hal Murray at 2017-01-19T16:18:40-08:00
Remove extra "ntpd" from Starting log message
- - - - -
bf537b38 by Hal Murray at 2017-01-19T17:02:35-08:00
Working on libsodium for NetBSD and FreeBSD
- - - - -
11 changed files:
- attic/sht.c
- docs/discover.txt
- docs/includes/ntp-conf-body.txt
- docs/miscopt.txt
- include/ntp.h
- ntpd/keyword-gen.c
- ntpd/ntp_config.c
- ntpd/ntp_proto.c
- ntpd/ntpd.c
- wafhelpers/check_sodium.py
- wafhelpers/configure.py
Changes:
=====================================
attic/sht.c
=====================================
--- a/attic/sht.c
+++ b/attic/sht.c
@@ -75,6 +75,8 @@ main (
progname = argv[0];
init_lib();
+ srandom(3); /* Squash warning from OpenBSD 6.0 */
+ /* warning: random() may return deterministic values... */
if (argc<=1) {
usage:
=====================================
docs/discover.txt
=====================================
--- a/docs/discover.txt
+++ b/docs/discover.txt
@@ -57,9 +57,9 @@ below or above specified stratum levels. By default, servers of all
strata are acceptable; however, the +tos+ command can be used to
restrict the acceptable range from the +floor+ option, inclusive, to the
+ceiling+ option, exclusive. Potential servers operating at the same
-stratum as the client will be avoided, unless the +cohort+ option is
-present. Additional filters can be supplied using the methods described
-on the link:authentic.html[Authentication Support] page.
+stratum as the client will be avoided. Additional filters can be
+supplied using the methods described on the
+link:authentic.html[Authentication Support] page.
The pruning process uses a set of unreach counters, one for each
association created by the configuration or discovery processes. At each
=====================================
docs/includes/ntp-conf-body.txt
=====================================
--- a/docs/includes/ntp-conf-body.txt
+++ b/docs/includes/ntp-conf-body.txt
@@ -169,7 +169,7 @@ Discovery" page (available as part of the HTML documentation).
// It omits the more general tinkering options. If you change this,
// be very sure to keep docs/miscopt.txt synchronized.
-`tos` [`ceiling` _ceiling_ | `cohort` \{ `0` | `1` } | `floor` _floor_ | `minclock` _minclock_ | `minsane` _minsane_]::
+`tos` [`ceiling` _ceiling_ | `floor` _floor_ | `minclock` _minclock_ | `minsane` _minsane_]::
This command affects the clock selection and clustering algorithms. It
can be used to select the quality and quantity of peers used to
synchronize the system clock and is most useful in manycast mode. The
@@ -179,12 +179,6 @@ Discovery" page (available as part of the HTML documentation).
Peers with strata above _ceiling_ will be discarded if there are at
least _minclock_ peers remaining. This value defaults to 15, but can
be changed to any number from 1 to 15.
- `cohort` \{0 | 1 };;
- This is a binary flag which enables (0) or disables (1) manycast
- server replies to manycast clients with the same stratum level. This
- is useful to reduce implosions where large numbers of clients with
- the same stratum level are present. The default is to enable these
- replies.
`floor` _floor_;;
Peers with strata below _floor_ will be discarded if there are at
least _minclock_ peers remaining. This value defaults to 1, but can
=====================================
docs/miscopt.txt
=====================================
--- a/docs/miscopt.txt
+++ b/docs/miscopt.txt
@@ -23,7 +23,7 @@ include::includes/misc-options.txt[]
// If you change this, be very sure to keep that synchronized.
[[tos]]
-+tos+ [+ceiling+ 'ceiling' | +cohort+ {+0+ | +1+} | +floor+ 'floor' | +maxclock+ 'maxclock' | +maxdist+ 'maxdist' | +minclock+ 'minclock' | +mindist+ 'mindist' | +minsane+ 'minsane' | +orphan+ 'stratum' | +orphanwait+ 'delay']::
++tos+ [+ceiling+ 'ceiling' | +floor+ 'floor' | +maxclock+ 'maxclock' | +maxdist+ 'maxdist' | +minclock+ 'minclock' | +mindist+ 'mindist' | +minsane+ 'minsane' | +orphan+ 'stratum' | +orphanwait+ 'delay']::
This command alters certain system variables used by the clock
selection and clustering algorithms. The default values of these
variables have been carefully optimized for a wide range of network
@@ -36,11 +36,6 @@ include::includes/misc-options.txt[]
Specify the maximum stratum (exclusive) for acceptable server
packets. The default is 16. See the link:discover.html[Automatic
Server Discovery] page for further details.
- +cohort+ { +0+ | +1+ };;
- Specify whether (1) or whether not (0) a server packet will be
- accepted for the same stratum as the client. The default is 0. See
- the link:discover.html[Automatic Server Discovery] page for further
- details.
+floor+ 'floor';;
Specify the minimum stratum (inclusive) for acceptable server
packets. The default is 1. See the link:discover.html[Automatic
=====================================
include/ntp.h
=====================================
--- a/include/ntp.h
+++ b/include/ntp.h
@@ -630,7 +630,7 @@ struct pkt {
#define PROTO_MINSANE 16
#define PROTO_FLOOR 17
#define PROTO_CEILING 18
-#define PROTO_COHORT 19
+/* #define PROTO_COHORT 19 */
#define PROTO_CALLDELAY 20
#define PROTO_MINDISP 21
#define PROTO_MAXDIST 22
=====================================
ntpd/keyword-gen.c
=====================================
--- a/ntpd/keyword-gen.c
+++ b/ntpd/keyword-gen.c
@@ -128,7 +128,6 @@ struct key_tok ntp_keywords[] = {
{ "minsane", T_Minsane, FOLLBY_TOKEN },
{ "floor", T_Floor, FOLLBY_TOKEN },
{ "ceiling", T_Ceiling, FOLLBY_TOKEN },
-{ "cohort", T_Cohort, FOLLBY_TOKEN },
{ "mindist", T_Mindist, FOLLBY_TOKEN },
{ "maxdisp", T_Maxdisp, FOLLBY_TOKEN },
{ "maxdist", T_Maxdist, FOLLBY_TOKEN },
=====================================
ntpd/ntp_config.c
=====================================
--- a/ntpd/ntp_config.c
+++ b/ntpd/ntp_config.c
@@ -1262,10 +1262,6 @@ config_tos(
item = PROTO_FLOOR;
break;
- case T_Cohort:
- item = PROTO_COHORT;
- break;
-
case T_Orphan:
item = PROTO_ORPHAN;
break;
=====================================
ntpd/ntp_proto.c
=====================================
--- a/ntpd/ntp_proto.c
+++ b/ntpd/ntp_proto.c
@@ -97,7 +97,6 @@ int sys_ceiling = STRATUM_UNSPEC - 1; /* cluster stratum ceiling */
int sys_minsane = 1; /* minimum candidates */
int sys_minclock = NTP_MINCLOCK; /* minimum candidates */
int sys_maxclock = NTP_MAXCLOCK; /* maximum candidates */
-int sys_cohort = 0; /* cohort switch */
int sys_orphan = STRATUM_UNSPEC + 1; /* orphan stratum */
int sys_orphwait = NTP_ORPHWAIT; /* orphan wait */
int sys_ttlmax; /* max ttl mapping vector index */
@@ -2838,10 +2837,6 @@ proto_config(
sys_ceiling = (int)dvalue;
break;
- case PROTO_COHORT: /* cohort switch (cohort) */
- sys_cohort = (int)dvalue;
- break;
-
case PROTO_FLOOR: /* stratum floor (floor) */
sys_floor = (int)dvalue;
break;
=====================================
ntpd/ntpd.c
=====================================
--- a/ntpd/ntpd.c
+++ b/ntpd/ntpd.c
@@ -544,7 +544,7 @@ ntpdmain(
char buf[1024]; /* Secret knowledge of msyslog buf length */
char *cp = buf;
- msyslog(LOG_NOTICE, "ntpd %s: Starting", ntpd_version());
+ msyslog(LOG_NOTICE, "%s: Starting", ntpd_version());
/* Note that every arg has an initial space character */
snprintf(cp, sizeof(buf), "Command line:");
=====================================
wafhelpers/check_sodium.py
=====================================
--- a/wafhelpers/check_sodium.py
+++ b/wafhelpers/check_sodium.py
@@ -1,6 +1,11 @@
def check_sodium(ctx):
- ctx.check_cc(header_name="sodium.h", includes=ctx.env.PLATFORM_INCLUDES, mandatory=True,
- errmsg="No\nFatal Error: Your system is missing libsodium")
- ctx.check_cc(lib="sodium", comment="Sodium crypto library", mandatory=True)
+ ctx.check_cc(header_name="sodium.h",
+ includes=ctx.env.PLATFORM_INCLUDES,
+ mandatory=True,
+ errmsg="No\nFatal Error: Your system is missing libsodium")
+ ctx.check_cc(lib="sodium",
+ libpath=ctx.env.PLATFORM_LIBPATH,
+ comment="Sodium crypto library",
+ mandatory=True)
=====================================
wafhelpers/configure.py
=====================================
--- a/wafhelpers/configure.py
+++ b/wafhelpers/configure.py
@@ -252,7 +252,8 @@ def cmd_configure(ctx, config):
ctx.env.PLATFORM_INCLUDES = ["/usr/local/include"]
ctx.env.PLATFORM_LIBPATH = ["/usr/local/lib"]
elif ctx.env.PLATFORM_TARGET == "netbsd":
- ctx.env.PLATFORM_LIBPATH = ["/usr/lib"]
+ ctx.env.PLATFORM_INCLUDES = ["/usr/pkg/include"]
+ ctx.env.PLATFORM_LIBPATH = ["/usr/lib", "/usr/pkg/lib"]
elif ctx.env.PLATFORM_TARGET == "win":
ctx.load("msvc")
View it on GitLab: https://gitlab.com/NTPsec/ntpsec/compare/b37454991e27152378fc46c5fe2f760953cd6dd5...bf537b38afb758e18a9b0fe4e9c13008b9e71ce4
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ntpsec.org/pipermail/vc/attachments/20170120/cf217845/attachment.html>
More information about the vc
mailing list