When the total_length field of the IP header is changed, we need to recompute its checksum.
It might be better to use IP_HEADER_LENGTH (a true constant) in the header constructor, saving a few instruction cycles since we wouldn't need to recompute the checksum.
When the total_length field of the IP header is changed, we need to recompute its checksum.
It might be better to use IP_HEADER_LENGTH (a true constant) in the header constructor, saving a few instruction cycles since we wouldn't need to recompute the checksum.