Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/bsd/ntp/dist Add a new config keyword "mdnstries" t...
details: https://anonhg.NetBSD.org/src/rev/b5649d77d260
branches: trunk
changeset: 759107:b5649d77d260
user: christos <christos%NetBSD.org@localhost>
date: Mon Nov 29 00:39:40 2010 +0000
description:
Add a new config keyword "mdnstries" that can be set to 0 to disable mdns.
diffstat:
external/bsd/ntp/dist/include/ntp_config.h | 4 +-
external/bsd/ntp/dist/ntpd/complete.conf | 1 +
external/bsd/ntp/dist/ntpd/keyword-gen.c | 5 +-
external/bsd/ntp/dist/ntpd/ntp_config.c | 17 +-
external/bsd/ntp/dist/ntpd/ntp_keyword.h | 1013 +++++++-------
external/bsd/ntp/dist/ntpd/ntp_parser.c | 1967 ++++++++++++++-------------
external/bsd/ntp/dist/ntpd/ntp_parser.h | 352 ++--
external/bsd/ntp/dist/ntpd/ntp_parser.y | 5 +-
external/bsd/ntp/dist/ntpd/ntpd.c | 4 +-
external/bsd/ntp/dist/ntpdc/nl.pl | 2 +-
10 files changed, 1704 insertions(+), 1666 deletions(-)
diffs (truncated from 4841 to 300 lines):
diff -r 68ed93e94211 -r b5649d77d260 external/bsd/ntp/dist/include/ntp_config.h
--- a/external/bsd/ntp/dist/include/ntp_config.h Sun Nov 28 20:37:24 2010 +0000
+++ b/external/bsd/ntp/dist/include/ntp_config.h Mon Nov 29 00:39:40 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ntp_config.h,v 1.1.1.1 2009/12/13 16:54:50 kardel Exp $ */
+/* $NetBSD: ntp_config.h,v 1.2 2010/11/29 00:39:40 christos Exp $ */
#ifndef NTP_CONFIG_H
#define NTP_CONFIG_H
@@ -198,6 +198,8 @@
queue *nic_rules;
struct sim_node *sim_details;
+
+ int mdnstries;
};
diff -r 68ed93e94211 -r b5649d77d260 external/bsd/ntp/dist/ntpd/complete.conf
--- a/external/bsd/ntp/dist/ntpd/complete.conf Sun Nov 28 20:37:24 2010 +0000
+++ b/external/bsd/ntp/dist/ntpd/complete.conf Mon Nov 29 00:39:40 2010 +0000
@@ -19,6 +19,7 @@
trustedkey 1 2 3 4 5 6 7 8 9 10 11 12
controlkey 12
requestkey 12
+mdnstries 5
enable auth ntp monitor
disable bclient calibrate kernel
tos beacon 3600 ceiling 16 cohort 0 floor 1 maxclock 10 maxdist 1.5 minclock 3 mindist 0.001 minsane 1 orphan 16
diff -r 68ed93e94211 -r b5649d77d260 external/bsd/ntp/dist/ntpd/keyword-gen.c
--- a/external/bsd/ntp/dist/ntpd/keyword-gen.c Sun Nov 28 20:37:24 2010 +0000
+++ b/external/bsd/ntp/dist/ntpd/keyword-gen.c Mon Nov 29 00:39:40 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: keyword-gen.c,v 1.1.1.1 2009/12/13 16:56:08 kardel Exp $ */
+/* $NetBSD: keyword-gen.c,v 1.2 2010/11/29 00:39:41 christos Exp $ */
/*
* keyword-gen.c -- generate keyword scanner finite state machine and
@@ -85,6 +85,7 @@
{ "iburst", T_Iburst, FOLLBY_TOKEN },
{ "key", T_Key, FOLLBY_TOKEN },
{ "maxpoll", T_Maxpoll, FOLLBY_TOKEN },
+{ "mdnstries", T_Mdnstries, FOLLBY_TOKEN },
{ "minpoll", T_Minpoll, FOLLBY_TOKEN },
{ "mode", T_Mode, FOLLBY_TOKEN },
{ "noselect", T_Noselect, FOLLBY_TOKEN },
@@ -318,7 +319,7 @@
fprintf(stderr,
"keyword-gen sst[%u] too small "
"for keyword '%s' id %d\n",
- COUNTOF(sst),
+ (int)COUNTOF(sst),
ntp_keywords[i].key,
token);
exit(4);
diff -r 68ed93e94211 -r b5649d77d260 external/bsd/ntp/dist/ntpd/ntp_config.c
--- a/external/bsd/ntp/dist/ntpd/ntp_config.c Sun Nov 28 20:37:24 2010 +0000
+++ b/external/bsd/ntp/dist/ntpd/ntp_config.c Mon Nov 29 00:39:40 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ntp_config.c,v 1.1.1.1 2009/12/13 16:56:10 kardel Exp $ */
+/* $NetBSD: ntp_config.c,v 1.2 2010/11/29 00:39:41 christos Exp $ */
/* ntp_config.c
*
@@ -272,6 +272,7 @@
static void config_system_opts(struct config_tree *);
static void config_logconfig(struct config_tree *);
static void config_phone(struct config_tree *);
+static void config_mdnstries(struct config_tree *);
static void config_qos(struct config_tree *);
static void config_setvar(struct config_tree *);
static void config_ttl(struct config_tree *);
@@ -378,6 +379,7 @@
ptree->nic_rules = create_queue();
ptree->auth.crypto_cmd_list = create_queue();
ptree->auth.trusted_key_list = create_queue();
+ ptree->mdnstries = 5;
}
@@ -896,6 +898,7 @@
case T_Flag2:
case T_Flag3:
case T_Flag4:
+ case T_Mdnstries:
fprintf(df, " %s %d",
keyword(atrv->attr),
atrv->value.i);
@@ -2721,6 +2724,17 @@
static void
+config_mdnstries(
+ struct config_tree *ptree
+ )
+{
+#ifdef HAVE_DNSREGISTRATION
+ extern int mdnstries;
+ mdnstries = ptree->mdnstries;
+#endif /* HAVE_DNSREGISTRATION */
+}
+
+static void
config_qos(
struct config_tree *ptree
)
@@ -3707,6 +3721,7 @@
config_unpeers(ptree);
config_fudge(ptree);
config_qos(ptree);
+ config_mdnstries(ptree);
}
#endif /* !SIM */
diff -r 68ed93e94211 -r b5649d77d260 external/bsd/ntp/dist/ntpd/ntp_keyword.h
--- a/external/bsd/ntp/dist/ntpd/ntp_keyword.h Sun Nov 28 20:37:24 2010 +0000
+++ b/external/bsd/ntp/dist/ntpd/ntp_keyword.h Mon Nov 29 00:39:40 2010 +0000
@@ -1,10 +1,8 @@
-/* $NetBSD: ntp_keyword.h,v 1.1.1.1 2009/12/13 16:56:18 kardel Exp $ */
-
/*
* ntp_keyword.h
*
* NOTE: edit this file with caution, it is generated by keyword-gen.c
- * Generated 2009-11-09 03:14:05 UTC diff_ignore_line
+ * Generated 2010-11-28 21:29:36 UTC diff_ignore_line
*
*/
#include "ntp_scanner.h"
@@ -12,7 +10,7 @@
#define LOWEST_KEYWORD_ID 258
-const char * const keyword_text[162] = {
+const char * const keyword_text[163] = {
/* 0 258 T_Age */ "age",
/* 1 259 T_All */ "all",
/* 2 260 T_Allan */ "allan",
@@ -89,97 +87,98 @@
/* 73 331 T_Maxclock */ "maxclock",
/* 74 332 T_Maxdist */ "maxdist",
/* 75 333 T_Maxpoll */ "maxpoll",
- /* 76 334 T_Minclock */ "minclock",
- /* 77 335 T_Mindist */ "mindist",
- /* 78 336 T_Minimum */ "minimum",
- /* 79 337 T_Minpoll */ "minpoll",
- /* 80 338 T_Minsane */ "minsane",
- /* 81 339 T_Mode */ "mode",
- /* 82 340 T_Monitor */ "monitor",
- /* 83 341 T_Month */ "month",
- /* 84 342 T_Multicastclient */ "multicastclient",
- /* 85 343 T_Nic */ "nic",
- /* 86 344 T_Nolink */ "nolink",
- /* 87 345 T_Nomodify */ "nomodify",
- /* 88 346 T_None */ "none",
- /* 89 347 T_Nopeer */ "nopeer",
- /* 90 348 T_Noquery */ "noquery",
- /* 91 349 T_Noselect */ "noselect",
- /* 92 350 T_Noserve */ "noserve",
- /* 93 351 T_Notrap */ "notrap",
- /* 94 352 T_Notrust */ "notrust",
- /* 95 353 T_Ntp */ "ntp",
- /* 96 354 T_Ntpport */ "ntpport",
- /* 97 355 T_NtpSignDsocket */ "ntpsigndsocket",
- /* 98 356 T_Orphan */ "orphan",
- /* 99 357 T_Panic */ "panic",
- /* 100 358 T_Peer */ "peer",
- /* 101 359 T_Peerstats */ "peerstats",
- /* 102 360 T_Phone */ "phone",
- /* 103 361 T_Pid */ "pid",
- /* 104 362 T_Pidfile */ "pidfile",
- /* 105 363 T_Pool */ "pool",
- /* 106 364 T_Port */ "port",
- /* 107 365 T_Preempt */ "preempt",
- /* 108 366 T_Prefer */ "prefer",
- /* 109 367 T_Protostats */ "protostats",
- /* 110 368 T_Pw */ "pw",
- /* 111 369 T_Qos */ "qos",
- /* 112 370 T_Randfile */ "randfile",
- /* 113 371 T_Rawstats */ "rawstats",
- /* 114 372 T_Refid */ "refid",
- /* 115 373 T_Requestkey */ "requestkey",
- /* 116 374 T_Restrict */ "restrict",
- /* 117 375 T_Revoke */ "revoke",
- /* 118 376 T_Saveconfigdir */ "saveconfigdir",
- /* 119 377 T_Server */ "server",
- /* 120 378 T_Setvar */ "setvar",
- /* 121 379 T_Sign */ "sign",
- /* 122 380 T_Statistics */ "statistics",
- /* 123 381 T_Stats */ "stats",
- /* 124 382 T_Statsdir */ "statsdir",
- /* 125 383 T_Step */ "step",
- /* 126 384 T_Stepout */ "stepout",
- /* 127 385 T_Stratum */ "stratum",
- /* 128 386 T_String */ NULL,
- /* 129 387 T_Sysstats */ "sysstats",
- /* 130 388 T_Tick */ "tick",
- /* 131 389 T_Time1 */ "time1",
- /* 132 390 T_Time2 */ "time2",
- /* 133 391 T_Timingstats */ "timingstats",
- /* 134 392 T_Tinker */ "tinker",
- /* 135 393 T_Tos */ "tos",
- /* 136 394 T_Trap */ "trap",
- /* 137 395 T_True */ "true",
- /* 138 396 T_Trustedkey */ "trustedkey",
- /* 139 397 T_Ttl */ "ttl",
- /* 140 398 T_Type */ "type",
- /* 141 399 T_Unconfig */ "unconfig",
- /* 142 400 T_Unpeer */ "unpeer",
- /* 143 401 T_Version */ "version",
- /* 144 402 T_WanderThreshold */ NULL,
- /* 145 403 T_Week */ "week",
- /* 146 404 T_Wildcard */ "wildcard",
- /* 147 405 T_Xleave */ "xleave",
- /* 148 406 T_Year */ "year",
- /* 149 407 T_Flag */ NULL,
- /* 150 408 T_Void */ NULL,
- /* 151 409 T_EOC */ NULL,
- /* 152 410 T_Simulate */ "simulate",
- /* 153 411 T_Beep_Delay */ "beep_delay",
- /* 154 412 T_Sim_Duration */ "simulation_duration",
- /* 155 413 T_Server_Offset */ "server_offset",
- /* 156 414 T_Duration */ "duration",
- /* 157 415 T_Freq_Offset */ "freq_offset",
- /* 158 416 T_Wander */ "wander",
- /* 159 417 T_Jitter */ "jitter",
- /* 160 418 T_Prop_Delay */ "prop_delay",
- /* 161 419 T_Proc_Delay */ "proc_delay"
+ /* 76 334 T_Mdnstries */ "mdnstries",
+ /* 77 335 T_Minclock */ "minclock",
+ /* 78 336 T_Mindist */ "mindist",
+ /* 79 337 T_Minimum */ "minimum",
+ /* 80 338 T_Minpoll */ "minpoll",
+ /* 81 339 T_Minsane */ "minsane",
+ /* 82 340 T_Mode */ "mode",
+ /* 83 341 T_Monitor */ "monitor",
+ /* 84 342 T_Month */ "month",
+ /* 85 343 T_Multicastclient */ "multicastclient",
+ /* 86 344 T_Nic */ "nic",
+ /* 87 345 T_Nolink */ "nolink",
+ /* 88 346 T_Nomodify */ "nomodify",
+ /* 89 347 T_None */ "none",
+ /* 90 348 T_Nopeer */ "nopeer",
+ /* 91 349 T_Noquery */ "noquery",
+ /* 92 350 T_Noselect */ "noselect",
+ /* 93 351 T_Noserve */ "noserve",
+ /* 94 352 T_Notrap */ "notrap",
+ /* 95 353 T_Notrust */ "notrust",
+ /* 96 354 T_Ntp */ "ntp",
+ /* 97 355 T_Ntpport */ "ntpport",
+ /* 98 356 T_NtpSignDsocket */ "ntpsigndsocket",
+ /* 99 357 T_Orphan */ "orphan",
+ /* 100 358 T_Panic */ "panic",
+ /* 101 359 T_Peer */ "peer",
+ /* 102 360 T_Peerstats */ "peerstats",
+ /* 103 361 T_Phone */ "phone",
+ /* 104 362 T_Pid */ "pid",
+ /* 105 363 T_Pidfile */ "pidfile",
+ /* 106 364 T_Pool */ "pool",
+ /* 107 365 T_Port */ "port",
+ /* 108 366 T_Preempt */ "preempt",
+ /* 109 367 T_Prefer */ "prefer",
+ /* 110 368 T_Protostats */ "protostats",
+ /* 111 369 T_Pw */ "pw",
+ /* 112 370 T_Qos */ "qos",
+ /* 113 371 T_Randfile */ "randfile",
+ /* 114 372 T_Rawstats */ "rawstats",
+ /* 115 373 T_Refid */ "refid",
+ /* 116 374 T_Requestkey */ "requestkey",
+ /* 117 375 T_Restrict */ "restrict",
+ /* 118 376 T_Revoke */ "revoke",
+ /* 119 377 T_Saveconfigdir */ "saveconfigdir",
+ /* 120 378 T_Server */ "server",
+ /* 121 379 T_Setvar */ "setvar",
+ /* 122 380 T_Sign */ "sign",
+ /* 123 381 T_Statistics */ "statistics",
+ /* 124 382 T_Stats */ "stats",
+ /* 125 383 T_Statsdir */ "statsdir",
+ /* 126 384 T_Step */ "step",
+ /* 127 385 T_Stepout */ "stepout",
+ /* 128 386 T_Stratum */ "stratum",
+ /* 129 387 T_String */ NULL,
+ /* 130 388 T_Sysstats */ "sysstats",
+ /* 131 389 T_Tick */ "tick",
+ /* 132 390 T_Time1 */ "time1",
+ /* 133 391 T_Time2 */ "time2",
+ /* 134 392 T_Timingstats */ "timingstats",
+ /* 135 393 T_Tinker */ "tinker",
+ /* 136 394 T_Tos */ "tos",
+ /* 137 395 T_Trap */ "trap",
+ /* 138 396 T_True */ "true",
+ /* 139 397 T_Trustedkey */ "trustedkey",
+ /* 140 398 T_Ttl */ "ttl",
+ /* 141 399 T_Type */ "type",
+ /* 142 400 T_Unconfig */ "unconfig",
+ /* 143 401 T_Unpeer */ "unpeer",
+ /* 144 402 T_Version */ "version",
+ /* 145 403 T_WanderThreshold */ NULL,
+ /* 146 404 T_Week */ "week",
+ /* 147 405 T_Wildcard */ "wildcard",
Home |
Main Index |
Thread Index |
Old Index