Don't update server-time too frequently.

This commit is contained in:
John Preston 2024-04-04 17:37:50 +04:00
parent a9c1970f41
commit 8df6d9db7e
2 changed files with 5 additions and 3 deletions

View File

@ -1651,7 +1651,9 @@ SessionPrivate::HandleResult SessionPrivate::handleOneReceived(
}
_sessionSalt = data.vnew_server_salt().v;
correctUnixtimeWithBadLocal(info.serverTime);
// Don't force time update here.
base::unixtime::update(info.serverTime);
if (_bindMsgId) {
LOG(("Message Info: bad_server_salt received while binding temp key, restarting."));
@ -2079,7 +2081,7 @@ void SessionPrivate::correctUnixtimeByFastRequest(
locker.unlock();
SyncTimeRequestDuration = duration;
base::unixtime::update(serverTime, true);
base::unixtime::update(serverTime);
return;
}
}

@ -1 +1 @@
Subproject commit beef65fac578a812dade36557f4c666ac3d3ba78
Subproject commit 3d1ea724a80c3e3a431a88a653d24f4f418eaea8