[ENet-discuss] totally flush the outgoing commands list
Arnaud Blanchard
arnaud.blanchard at ensea.fr
Wed Sep 11 02:58:47 PDT 2013
Hi,
Each time we use enet, we have the same problem when we have lot of data
to send.
Eventhough we call very regularly enet_host_service the outgoing command
list is continuously growing and the lag to retrieve the data is
continuously increasing. Even using enet_host_flush does not solve the
problem.
We wonder if it can be a kind of timeout somewhere or a limit in the
number of packet sent in one shout. Anyway, the only solution (see
below) that we have found is to loop on calling enet_host_service until
the list is empty, but it is not very clean or satisfactory.
Any explanation ?
Thank you for your help, best regards,
Arnaud Blancahrd
for(i=0;i<host->peerCount;i++)
{
while ( !enet_list_empty(&(peers[i].outgoingReliableCommands))
|| !enet_list_empty(&(peers[i].outgoingUnreliableCommands)))
{
enet_host_service(0);
}
}
--
Research engineer
Neurocybernetic team - ETIS
http://arnaudblanchard.ensea.fr
More information about the ENet-discuss
mailing list