c++ - UDP sendto() and recvfrom() max buffer size -


I understand that with these tasks I can use default max buffer size 65507 (5535 - IPv4 header - UDP header ). However, is there any way to change this? I should be able to send a big buffer ~ 66000 bytes. I tried to use the setockopt () function, but it did not seem to work.

Thank you!

no.

UDP offers only datagrams in the form of data portions of IP packets, an IP packet has a 16-bit length area, thus limiting data with headers of 2 ^ 16 bytes, or UDP There is no way to handle 65507 bytes (not an IPv4 option) for the data portion, besides handling large packets with UDP and dividing them in several packets and reassigning etc.


Comments