This commit is contained in:
2021-03-01 11:10:02 +01:00
parent fc101e30f4
commit 991f2724a6

View File

@ -147,8 +147,8 @@ void networkSntpEngine(void *handle) {
srcAddr[0], srcAddr[1], srcAddr[2], srcAddr[3],
srcPort);
coloredMsg(LOG_BLUE, "nes, received in the %d. cycles", localHandle->retryCount);
localHandle->seconds = localHandle->ntpMsg.xmt_h - UNIX_NTP_EPOCH_DIFF;
coloredMsg(LOG_BLUE, "nes, seconds: %lu", localHandle->seconds);
localHandle->seconds = ((uint64_t)localHandle->ntpMsg.xmt_h) - UNIX_NTP_EPOCH_DIFF;
coloredMsg(LOG_BLUE, "nes, seconds: %llu", localHandle->seconds);
localHandle->sntpState = SNTP_STATE_DONE;
} else {
coloredMsg(LOG_BLUE, "nes, invalid number of octets received: %d", recvLen);