Fix compilation errors and warnings

This commit is contained in:
Jérôme Leclercq
2021-07-07 22:16:22 +02:00
parent 1f6937ab1b
commit 309fd547e1
14 changed files with 38 additions and 30 deletions

View File

@@ -264,8 +264,8 @@ namespace Nz
for (unsigned int i = 0; i < 8; ++i)
{
u_short addressPart = htons(address[i]);
socketAddress->sin6_addr.s6_addr[i * 2 + 0] = addressPart >> 0;
socketAddress->sin6_addr.s6_addr[i * 2 + 1] = addressPart >> 8;
socketAddress->sin6_addr.s6_addr[i * 2 + 0] = static_cast<UCHAR>(addressPart >> 0);
socketAddress->sin6_addr.s6_addr[i * 2 + 1] = static_cast<UCHAR>(addressPart >> 8);
}
return sizeof(sockaddr_in6);

View File

@@ -452,7 +452,7 @@ namespace Nz
#endif
}
SocketState SocketImpl::PollConnection(SocketHandle handle, const IpAddress& address, UInt64 msTimeout, SocketError* error)
SocketState SocketImpl::PollConnection(SocketHandle handle, const IpAddress& /*address*/, UInt64 msTimeout, SocketError* error)
{
// Wait until socket is available for writing or an error occurs (ie when connection succeeds or fails)
WSAPOLLFD descriptor;