]> The Tcpdump Group git mirrors - tcpdump/blobdiff - print-tcp.c
Fix the pointer tests in the non-ndoified TTEST2() macro as well.
[tcpdump] / print-tcp.c
index ea57132221a76e754e23ed0f82a06063c82546d0..e2559ecf64ca0335eabd3db96303d0570c44942e 100644 (file)
@@ -759,7 +759,7 @@ tcp_verify_signature(const struct ip *ip, const struct tcphdr *tp,
                 ip6 = (struct ip6_hdr *)ip;
                 MD5_Update(&ctx, (char *)&ip6->ip6_src, sizeof(ip6->ip6_src));
                 MD5_Update(&ctx, (char *)&ip6->ip6_dst, sizeof(ip6->ip6_dst));
-                len32 = htonl(ntohs(ip6->ip6_plen));
+                len32 = htonl(EXTRACT_16BITS(&ip6->ip6_plen));
                 MD5_Update(&ctx, (char *)&len32, sizeof(len32));
                 nxt = 0;
                 MD5_Update(&ctx, (char *)&nxt, sizeof(nxt));