[ENet-discuss] ENet doesn't do servers?

Steve Williams stevewilliams at kromestudios.com
Thu Dec 13 19:54:48 PST 2007


Only TCP requires accept to be called.  UDP (which enet uses) is not a 
persistent connection and only requires recv() to be called.

We have just released a four-player client/server game on Xbox 360 that 
uses enet for the networking over Xbox LIVE and it worked great.

-- 
Sly


Shawn Yarbrough wrote:
> I must be missing something, but as far as I can tell, enet doesn't 
> work for servers?
>
> Some grepping of the ENet code base shows that the accept() system 
> call is never called
> anywhere.  (Unless the user calls enet_socket_accept() directly, which 
> none of the
> ENet instructions say is expected to ever happen.)
>
> But the UNIX listen(2) man page says:
>
>     To accept connections, a socket is first created with socket(2),
>     a willingness to accept incoming connections and a queue limit
>     for incoming connections are specified with listen(), and then
>     the connections are accepted with accept(2).
>
> ENet does call listen.  Then it polls/selects on the socket waiting 
> for activity, but
> when activity appears, it doesn't seem to do the right thing for a 
> server which would
> be to do an accept() system call.
>
> If I could find one example of a working server, using ENet, it would 
> probably help me.
>
> Some ENet developer please correct me if I'm wrong, or please confirm 
> that I'm right
> and I'll help improve ENet to fix the problem.
>
> Regards,
>
> Shawn Yarbrough
>



This message and its attachments may contain legally privileged or confidential information. This message is intended for the use of the individual or entity to which it is addressed. If you are not the addressee indicated in this message, or the employee or agent responsible for delivering the message to the intended recipient, you may not copy or deliver this message or its attachments to anyone. Rather, you should permanently delete this message and its attachments and kindly notify the sender by reply e-mail. Any content of this message and its attachments, which does not relate to the official business of the sending company must be taken not to have been sent or endorsed by the sending company or any of its related entities. No warranty is made that the e-mail or attachment(s) are free from computer virus or other defect.



More information about the ENet-discuss mailing list