Reply To: Packet Length via ip_len failed?

Home Forums Discussions General Discussion Packet Length via ip_len failed? Reply To: Packet Length via ip_len failed?

#6543

Vadim Smirnov
Moderator

pIpHeader->ip_len is in network byte order, so it should be:

DWORD dwDataLength = ntohs(pIpHeader->ip_len) - ( pIpHeader->ip_hl*4 + pTcpHeader->th_off*4);