Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Problem with asynchronous sockets

This topic is 5799 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

Here''s a really odd problem: My client program using asynchronous sockets, which worked perfectly just recently, stopped working when I added OpenGL support to the window. I removed the OpenGL stuff and thought ''I''ll make the network code work properly, and THEN add OpenGL'', but the asynchronous sockets still didn''t work. No messages are sent to the window specified with WSAASyncSelect. Even though I get connected and can send data to the server, which receives it and sends data back, I get no notification that the socket connected or received data. I use a SetupSocket function, which takes one pointer to a socket, one window handle, the port to bind and a bool determining if the socket should use SO_REUSEADDR or not. The function creates the socket, binds it to the port, sets it to use/not use SO_REUSEADDR and call the WSAASyncSelect() function with the correct socket and window handle, a message to send to the window, and FD_READ | FD_CONNECT | FD_CLOSE. Does anyone have any idea of what might be the reason for the messages not arriving to the window?

Three shall be the number thou shall count, and the number of the counting shall be three...

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!