mirror of
https://gitlab.com/chrony/chrony.git
synced 2025-12-06 17:55:06 -05:00
ntp: rework initial burst
Instead of making the initial burst only once and immediately after chronyd start (even when iburst is specified together with the offline option), trigger the burst whenever the connectivity changes from offline to online.
This commit is contained in:
3
conf.c
3
conf.c
@@ -1771,11 +1771,10 @@ CNF_AddInitSources(void)
|
||||
/* Get the default NTP params */
|
||||
CPS_ParseNTPSourceAdd(dummy_hostname, &cps_source);
|
||||
|
||||
/* Add the address as an offline iburst server */
|
||||
/* Add the address as a server specified with the iburst option */
|
||||
ntp_addr.ip_addr = *(IPAddr *)ARR_GetElement(init_sources, i);
|
||||
ntp_addr.port = cps_source.port;
|
||||
cps_source.params.iburst = 1;
|
||||
cps_source.params.connectivity = SRC_OFFLINE;
|
||||
|
||||
NSR_AddSource(&ntp_addr, NTP_SERVER, &cps_source.params, NULL);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user