In my application, I am trying to send and receive datagrams to different servers as quickly as possible. I noticed that increasing the sending rate is greatly lowering the percentage of responses I receive for a given # of sends. I believe one cause could be recvfrom()'s queue is filling faster than I can call the function to read the packets, reaching the end and dropping a a lot of packets. Is there a way I can check how full the receive buffer is for a socket?
This is on Windows, not Linux, and I would prefer a programmatic approach.