This error is non-fatal and should be handled by retrying.
With this, the error handling is moved before the logging and addition of the count variable. In case of error, len would be -1 on !windows, so it would add a negative value.
Maybe this also needs to happen for UDP, I'm not sure. The current UDPSocket::Receive implementation has no read loop anyway, so not sure how that works when EINTR is returned there...
This error is non-fatal and should be handled by retrying.
With this, the error handling is moved before the logging and addition of the count variable. In case of error, len would be -1 on !windows, so it would add a negative value.
Errors other than EINTR are thrown as usual.