X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/84ef17ac0eecb3efc11a63c3f2c578ae78732c02..1a04b92e365f5ed01ca38619b41bcc4fc9cbd63c:/print-icmp.c diff --git a/print-icmp.c b/print-icmp.c index ff65a854..a9a72014 100644 --- a/print-icmp.c +++ b/print-icmp.c @@ -411,7 +411,7 @@ icmp_print(netdissect_options *ndo, const u_char *bp, u_int plen, const u_char * case ICMP_UNREACH_NEEDFRAG: { - register const struct mtu_discovery *mp; + const struct mtu_discovery *mp; mp = (const struct mtu_discovery *)(const u_char *)&dp->icmp_void; mtu = EXTRACT_BE_U_2(&mp->nexthopmtu); if (mtu) { @@ -446,8 +446,8 @@ icmp_print(netdissect_options *ndo, const u_char *bp, u_int plen, const u_char * case ICMP_ROUTERADVERT: { - register const struct ih_rdiscovery *ihp; - register const struct id_rdiscovery *idp; + const struct ih_rdiscovery *ihp; + const struct id_rdiscovery *idp; u_int lifetime, num, size; (void)snprintf(buf, sizeof(buf), "router advertisement"); @@ -602,7 +602,7 @@ icmp_print(netdissect_options *ndo, const u_char *bp, u_int plen, const u_char * * however not all implementations set the length field proper. */ if (!ext_dp->icmp_length && - ND_TTEST2(ext_dp->icmp_ext_version_res, plen - ICMP_EXTD_MINLEN)) { + ND_TTEST_LEN(ext_dp->icmp_ext_version_res, plen - ICMP_EXTD_MINLEN)) { vec[0].ptr = (const uint8_t *)(const void *)&ext_dp->icmp_ext_version_res; vec[0].len = plen - ICMP_EXTD_MINLEN; if (in_cksum(vec, 1)) { @@ -623,7 +623,7 @@ icmp_print(netdissect_options *ndo, const u_char *bp, u_int plen, const u_char * } hlen = plen - ICMP_EXTD_MINLEN; - if (ND_TTEST2(ext_dp->icmp_ext_version_res, hlen)) { + if (ND_TTEST_LEN(ext_dp->icmp_ext_version_res, hlen)) { vec[0].ptr = (const uint8_t *)(const void *)&ext_dp->icmp_ext_version_res; vec[0].len = hlen; ND_PRINT((ndo, ", checksum 0x%04x (%scorrect), length %u",