The SntpClient class is notifying failures multiple times. This can be reproduced by pulling the network cable from machine. I added the following check to avoid this:
public void BeginGetDate(Action<DateTime> getTime, Action failure)
{
_index += 1;
if (_hosts.Length <= _index)
{
if (_hosts.Length == _index)
{
failure();
}
return;
}
I suspect that there may be a deeper problem here but the fix isn't obvious to me.
The SntpClient class is notifying failures multiple times. This can be reproduced by pulling the network cable from machine. I added the following check to avoid this:
I suspect that there may be a deeper problem here but the fix isn't obvious to me.