Home > other >  About the sockets sendto function sends a TCP packet cannot too big problem! Pray god help!
About the sockets sendto function sends a TCP packet cannot too big problem! Pray god help!

Time:09-16

I recently got a project to raw socket captured packets to reconstruct the IP and TCP header information, forward again, but I find some of the far more than the 1500 bytes captured packets, but after reconstruction by sendto function sends, there will be a send failure (in the case of the reason for the error 90: the bag is too big), because the project forward, I can only use sendto function for whether sendto function sends a TCP packet size must be smaller than 1500 bytes? Hope to have a great god can solve, thank you very much!

CodePudding user response:

Sendto for UDP, isn't it? Unlike TCP header (guess), arguably, split package is too big, should be can, sendto bag does not greater than 1500, but for TCP, even greater than 1500, can also be automatically by the lower resolution without error,
The landlord to remove the package to try?
  • Related