[ENet-discuss] How to temporarily keep a host from acceptingincoming connection requests?

Philip Bennefall philip at u7142039.fsdata.se
Mon Jun 21 13:20:58 PDT 2010


Hello there,

Thanks for the tip. I relocated your original message and followed the same 
steps, though I made it a boolean rather than an int as I don't really 
require anything other than TRUE or FALSE.

Kind regards,

Philip Bennefall
----- Original Message ----- 
From: "Benoit Germain" <bgermain at ubisoft.fr>
To: <philip at blastbay.com>; "Discussion of the ENet library" 
<enet-discuss at cubik.org>
Sent: Monday, June 21, 2010 9:05 AM
Subject: RE: [ENet-discuss] How to temporarily keep a host from 
acceptingincoming connection requests?



> -----Message d'origine-----
> De : enet-discuss-bounces at cubik.org [mailto:enet-discuss-
> bounces at cubik.org] De la part de Philip Bennefall
> Envoyé : lundi 21 juin 2010 02:30
> À : Discussion of the ENet library
> Objet : Re: [ENet-discuss] How to temporarily keep a host from
> accepting incoming connection requests?
>
> Hi Lee,
>
> I also am interested in doing something like this, as I can then make
> it
> even easier for the users of my scripting engine to set up hosts that
> accept
> connections at certain times but not at others. Exactly which function
> would
> i have to modify to accomplish this? I assume I should be looking in
> the
> file called protocol.c? Some hints would be very much appreciated.
> Perhaps a
> quick wrapper function in the next minor build
> (enet_host_disable_incoming_connections) or similar?
>
> Kind regards,
>
> Philip Bennefall

I am currently using the solution I described in my original post, which 
works just fine as far as I can tell. Since the host structure is public, 
there is no need for an api function, just change host->sessionPassword 
whenever you need to.

Regards,


Benoit.


--------------------------------------------------------------------------------



Internal Virus Database is out of date.
Checked by AVG - www.avg.com
Version: 8.5.432 / Virus Database: 271.1.1/2662 - Release Date: 02/01/10 
12:37:00



More information about the ENet-discuss mailing list