mirror of
https://gitlab.com/chrony/chrony.git
synced 2025-12-03 18:35:06 -05:00
ntp: avoid unnecessary restart of resolving round on refresh
Don't call NSR_ResolveSources() when a resolving round is already started. This cuts the number of calls of the system resolver made due to the refresh command to half.
This commit is contained in:
@@ -1056,6 +1056,9 @@ resolve_source_replacement(SourceRecord *record, int refreshment)
|
||||
us->address = *record->remote_addr;
|
||||
|
||||
append_unresolved_source(us);
|
||||
|
||||
/* Don't restart resolving round if already running */
|
||||
if (!resolving_source)
|
||||
NSR_ResolveSources();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user