What happens with TCP packets between two Socket.BeginReceive calls?

Posted by Rodrigo on Stack Overflow See other posts from Stack Overflow or by Rodrigo
Published on 2010-04-08T03:59:57Z Indexed on 2010/04/08 8:03 UTC
Read the original article Hit count: 349

Filed under:
|
|
|
|

I have a doubt about socket programming. I am developing a TCP packet sniffer. I am using Socket.BeginAccept, Socket.BeginReceive to capture every packet, but when a packet is received I have to process something. It is a fast operation, but would take some milliseconds, and then call BeginReceive again.

My question is, what would happen if some packets are sent while I am processing, and haven't called BeginReceive? Are packets lost, or are they buffered internally? Is there a limit?

© Stack Overflow or respective owner

Related posts about sockets

Related posts about c#