Raised This Month: $ Target: $400
 0% 

Socket related question.


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
OvidiuS
Chillaxin'
Join Date: Dec 2009
Location: Serbia
Old 06-15-2012 , 19:11   Socket related question.
Reply With Quote #1

It seems that i don't understand sockets very well.

I have one example, i'm not sure what is happening with sockets in these moments:

Server send a socket. After 0.1 another socket is sent by the same server.
Now two sockets are traveling to destination ( ip and port of my listen socket ). Each of that sockets are some strings.

Listen socket (socket_accept function) is thinking (entity think) in 0.5 interval. First socket arrives. Second socket arrives.

1. What happens when socket_accept is called? If i pass data to buffer will it be mixed, or socket_accept function will accept first socket, than in next think accept second socket?

2. For how long sent socket can "stay in air" before accepting?
I guess until listen socket is closed?

That's all i want to know. Maybe some of these questions are dumb, but i haven't found any answer to this.

Last edited by OvidiuS; 06-15-2012 at 19:24.
OvidiuS is offline
Send a message via Skype™ to OvidiuS
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 06:13.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode