[ENet-discuss] connect timeout

Krasimir Marinov krasi at jklsemi.com
Fri Oct 25 03:02:45 PDT 2013


I got it!

The timeouts work as expected.

The problem is that I was giving the enet_host_service() timeout of 60
seconds and since there was no traffic to “wake-up” select() the expired
packets are checked after the 60 seconds timeout expires.


On Fri, Oct 25, 2013 at 11:53 AM, Ruud van Gaal <ruud at racer.nl> wrote:

> You might want to check enet.h for ENET_PEER_TIMEOUT_MINIMUM and
> ENET_PEER_TIMEOUT_MAXIMUM.
> However, I also believed that the peer timeout could be set with a
> function call the last couple of versions...
>
> Ruud
>
>
> On Thu, Oct 24, 2013 at 11:09 PM, Krasimir Marinov <krasi at jklsemi.com>wrote:
>
>> Hi,
>>
>> First thanks for the nice library!
>>
>> I’ve a question related to tweaking the timeout on connect.
>>
>> I'd like the connection attempt to timeout, i.e. get DISCONNECT event,
>> asap in the case of the "server" is missing, i.e. the peer host is not
>> available.
>>
>> I've played with enet_peer_timeout(), setting different values on the
>> peer returned from enet_host_connect() call, but this is w/o any effect - I
>> get the DISCONNECT event after 60 seconds, no matter what values I pass to
>> enet_peer_timeout().
>>
>> Do I miss something? Is this the correct way to tweak the connect timeout?
>>
>> _______________________________________________
>> ENet-discuss mailing list
>> ENet-discuss at cubik.org
>> http://lists.cubik.org/mailman/listinfo/enet-discuss
>>
>>
>
> _______________________________________________
> ENet-discuss mailing list
> ENet-discuss at cubik.org
> http://lists.cubik.org/mailman/listinfo/enet-discuss
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cubik.org/pipermail/enet-discuss/attachments/20131025/581557d6/attachment.html>


More information about the ENet-discuss mailing list