winsock sendto() UDP problem
Posted on 2001-06-18
I?m writing a UDP server, using Winsock API 1.1 and VC++ 1.52.
I?ve got a problem using sendto() function. In MSDN they say that the function returns the number of bytes sent, that can be less then the buffer?s length passed as a parameter in sendto(). Is the winsock expecting the last part(s) of the buffer in order to send a complete datagram to the destination, or it is sending an incomplete datagram right away using only the bytes processed (I mean the first part of the buffer)?
How can I get the maximum datagram length? Is the WSAData.iMaxUdpDg value appropriate?