Fixes sign-compare warnings

This commit is contained in:
Marcus Minhorst 2025-07-18 18:47:44 -04:00 committed by Ricardo Luís Vaz Silva
commit 9b0f5d9b0d
41 changed files with 109 additions and 108 deletions

View file

@ -494,7 +494,7 @@ static void SendPacket(const sockaddr_in& to)
// Huge packets should be sent out as sequences, not as one big packet, otherwise it's prone
// to high amounts of congestion and reordering needed.
if (NetBufferLength > MAX_MSGLEN)
I_FatalError("Netbuffer overflow: Tried to send %u bytes of data", NetBufferLength);
I_FatalError("Netbuffer overflow: Tried to send %lu bytes of data", NetBufferLength);
assert(!(NetBuffer[0] & NCMD_COMPRESSED));
@ -973,7 +973,7 @@ static bool HostGame(int arg, bool forcedNetMode)
}
if (MaxClients > MAXPLAYERS)
I_FatalError("Cannot host a game with %u players. The limit is currently %u", MaxClients, MAXPLAYERS);
I_FatalError("Cannot host a game with %u players. The limit is currently %lu", MaxClients, MAXPLAYERS);
GenerateGameID();
NetworkClients += 0;
@ -1247,7 +1247,7 @@ static bool JoinGame(int arg)
throw CExitEvent(0);
}
for (size_t i = 1u; i < MaxClients; ++i)
for (int i = 1u; i < MaxClients; ++i)
{
if (Connected[i].Status != CSTAT_NONE)
Connected[i].Status = CSTAT_READY;