util: add functions for zeroing and comparing NTP timestamps

This commit is contained in:
Miroslav Lichvar
2016-10-24 16:46:29 +02:00
parent 0e273939d2
commit 6e9c04896b
4 changed files with 67 additions and 30 deletions

View File

@@ -209,8 +209,8 @@ get_record(IPAddr *ip)
record->ntp_rate = record->cmd_rate = INVALID_RATE;
record->ntp_timeout_rate = INVALID_RATE;
record->flags = 0;
record->ntp_rx_ts.hi = record->ntp_rx_ts.lo = 0;
record->ntp_tx_ts.hi = record->ntp_tx_ts.lo = 0;
UTI_ZeroNtp64(&record->ntp_rx_ts);
UTI_ZeroNtp64(&record->ntp_tx_ts);
return record;
}