Sign in to follow this  

Winsocks(Connections/Per Port)

This topic is 3864 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Well I read somewhere that for each port you can have only one connection in winsocks? Is true If so how would you get around this because I don't want to create a port for each connection. I googled it and I couldn't really find anything. If someone could link me to an article or explain I would be very thankful.

Share this post


Link to post
Share on other sites
Each socket can only be bound to single port for that given protocol (TCP/UDP).

When TCP server receives connection request, you call accept method, and a new socket is created, through which the server will then be communicating. Port binding here is automatic and of no concern to you, it's part of TCP layer.

When client requests a connection to the server, its port will be automatically allocated as well.

UDP doesn't use connections, so server will be listening on single post via single socket and handle all communication through there.

Share this post


Link to post
Share on other sites

This topic is 3864 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this