limit number of packets that can be received per iteration of protocol loop

This commit is contained in:
Lee Salzman
2014-09-29 15:49:34 +03:00
parent d85a037ec4
commit 6ef4e7d277
+3 -1
View File
@@ -1191,7 +1191,9 @@ commandError:
static int
enet_protocol_receive_incoming_commands (ENetHost * host, ENetEvent * event)
{
for (;;)
int packets;
for (packets = 0; packets < 256; ++ packets)
{
int receivedLength;
ENetBuffer buffer;