How can I be sure that UDP messages are received in order?
Answer / chaitanya
You can't. What you can do is make sure that messages are processed in order by using a numbering system as mentioned in ``5.5 How can I be sure that a UDP message is received?''. If you need your messages to be received and be received in order you should really consider switching to TCP. It is unlikely that you will be able to do a better job implementing this sort of protocol than the TCP people already have, without a significant investment of time.
Is This Answer Correct ? | 0 Yes | 0 No |
Whats the difference between select() and poll()?
How is a socket created?
What is the difference between close() and shutdown()?
What is a sae socket?
How can I listen on more than one port at a time?
If bind() fails, what should I do with the socket descriptor?
What is the difference between connected and unconnected sockets?
What is the difference between read() and recv()?
How to find other end of unix socket connection?
Why do we need sockets?
over the socket? Is there a way to have a dynamic buffer? What does one do when one does not know how much information is coming?
Why do I keep getting EINTR from the socket calls?