Deleted Added
full compact
ntp_config.c (82498) ntp_config.c (106163)
1/*
2 * ntp_config.c - read and apply configuration information
3 */
4#ifdef HAVE_CONFIG_H
5# include <config.h>
6#endif
7
8#ifdef HAVE_NETINFO

--- 10 unchanged lines hidden (view full) ---

19#include "ntp_cmdargs.h"
20
21#ifdef PUBKEY
22# include "ntp_crypto.h"
23#endif /* PUBKEY */
24
25#include <stdio.h>
26#include <ctype.h>
1/*
2 * ntp_config.c - read and apply configuration information
3 */
4#ifdef HAVE_CONFIG_H
5# include <config.h>
6#endif
7
8#ifdef HAVE_NETINFO

--- 10 unchanged lines hidden (view full) ---

19#include "ntp_cmdargs.h"
20
21#ifdef PUBKEY
22# include "ntp_crypto.h"
23#endif /* PUBKEY */
24
25#include <stdio.h>
26#include <ctype.h>
27#ifdef HAVE_SYS_PARAM_H
27#include <sys/param.h>
28#include <sys/param.h>
29#endif
28#include <signal.h>
29#ifndef SIGCHLD
30# define SIGCHLD SIGCLD
31#endif
32#if !defined(VMS)
33# ifdef HAVE_SYS_WAIT_H
34# include <sys/wait.h>
35# endif

--- 38 unchanged lines hidden (view full) ---

74 * requestkey [ key]
75 * controlkey [ key ]
76 * trap [ addr ]
77 * fudge [ addr ] [ stratum ] [ refid ] ...
78 * pidfile [ ]
79 * setvar [ ]
80 * logfile logfile
81 * logconfig [+|-|=][{sync|sys|peer|clock}{{,all}{info|statistics|events|status}}]...
30#include <signal.h>
31#ifndef SIGCHLD
32# define SIGCHLD SIGCLD
33#endif
34#if !defined(VMS)
35# ifdef HAVE_SYS_WAIT_H
36# include <sys/wait.h>
37# endif

--- 38 unchanged lines hidden (view full) ---

76 * requestkey [ key]
77 * controlkey [ key ]
78 * trap [ addr ]
79 * fudge [ addr ] [ stratum ] [ refid ] ...
80 * pidfile [ ]
81 * setvar [ ]
82 * logfile logfile
83 * logconfig [+|-|=][{sync|sys|peer|clock}{{,all}{info|statistics|events|status}}]...
82 * enable auth|bclient|pll|kernel|monitor|stats
83 * disable auth|bclient|pll|kernel|monitor|stats
84 * enable auth|bclient|pll|kernel|monitor|stats|calibrate
85 * disable auth|bclient|pll|kernel|monitor|stats|calibrate
84 * phone ...
85 * pps device [assert|clear] [hardpps]
86 * priority high|normal
87 */
88
89/*
90 * Translation table - keywords to function index
91 */

--- 143 unchanged lines hidden (view full) ---

235};
236
237/*
238 * "enable", "disable" modifier keywords
239 */
240static struct keyword flags_keywords[] = {
241 { "auth", PROTO_AUTHENTICATE },
242 { "bclient", PROTO_BROADCLIENT },
86 * phone ...
87 * pps device [assert|clear] [hardpps]
88 * priority high|normal
89 */
90
91/*
92 * Translation table - keywords to function index
93 */

--- 143 unchanged lines hidden (view full) ---

237};
238
239/*
240 * "enable", "disable" modifier keywords
241 */
242static struct keyword flags_keywords[] = {
243 { "auth", PROTO_AUTHENTICATE },
244 { "bclient", PROTO_BROADCLIENT },
245 { "calibrate", PROTO_CAL },
243 { "kernel", PROTO_KERNEL },
244 { "monitor", PROTO_MONITOR },
245 { "ntp", PROTO_NTP },
246 { "kernel", PROTO_KERNEL },
247 { "monitor", PROTO_MONITOR },
248 { "ntp", PROTO_NTP },
246 { "stats", PROTO_FILEGEN },
247 { "pps", PROTO_PPS },
249 { "pps", PROTO_PPS },
248 { "calibrate", PROTO_CAL },
250 { "stats", PROTO_FILEGEN },
249 { "", CONFIG_UNKNOWN }
250};
251
252/*
253 * "pps" modifier keywords
254 */
255static struct keyword pps_keywords[] = {
256 { "assert", CONF_PPS_ASSERT },

--- 1839 unchanged lines hidden (view full) ---

2096 }
2097 }
2098#ifdef DEBUG
2099 if (debug) {
2100 printf("resolving %s\n", name);
2101 }
2102#endif
2103
251 { "", CONFIG_UNKNOWN }
252};
253
254/*
255 * "pps" modifier keywords
256 */
257static struct keyword pps_keywords[] = {
258 { "assert", CONF_PPS_ASSERT },

--- 1839 unchanged lines hidden (view full) ---

2098 }
2099 }
2100#ifdef DEBUG
2101 if (debug) {
2102 printf("resolving %s\n", name);
2103 }
2104#endif
2105
2104 (void)fprintf(res_fp, "%s %d %d %d %d %d %d %d %s\n", name,
2106 (void)fprintf(res_fp, "%s %d %d %d %d %d %d %u %s\n", name,
2105 mode, version, minpoll, maxpoll, flags, ttl, keyid, keystr);
2106#ifdef DEBUG
2107 if (debug > 1)
2107 mode, version, minpoll, maxpoll, flags, ttl, keyid, keystr);
2108#ifdef DEBUG
2109 if (debug > 1)
2108 printf("config: %s %d %d %d %d %x %d %08x %s\n", name, mode,
2110 printf("config: %s %d %d %d %d %x %d %u %s\n", name, mode,
2109 version, minpoll, maxpoll, flags, ttl, keyid, keystr);
2110#endif
2111
2112#else /* SYS_VXWORKS */
2113 /* save resolve info to a struct */
2114#endif /* SYS_VXWORKS */
2115}
2116

--- 168 unchanged lines hidden ---
2111 version, minpoll, maxpoll, flags, ttl, keyid, keystr);
2112#endif
2113
2114#else /* SYS_VXWORKS */
2115 /* save resolve info to a struct */
2116#endif /* SYS_VXWORKS */
2117}
2118

--- 168 unchanged lines hidden ---