X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/9dd6f72a8cb559e122b73ebd82dcddf36870df19..ff1df423b6a8cda80cef88efa8a3162abcfd0e6e:/print-pim.c diff --git a/print-pim.c b/print-pim.c index 16bfa625..f023207d 100644 --- a/print-pim.c +++ b/print-pim.c @@ -23,9 +23,9 @@ #include "config.h" #endif -#include +#include -#include "interface.h" +#include "netdissect.h" #include "addrtoname.h" #include "extract.h" @@ -640,12 +640,14 @@ pimv2_check_checksum(const u_char *bp, const u_char *bp2, u_int len) vec[0].len = len; cksum = in_cksum(vec, 1); return (cksum ? INCORRECT : CORRECT); +#ifdef INET6 } else if (IP_V(ip) == 6) { const struct ip6_hdr *ip6; ip6 = (const struct ip6_hdr *)bp2; cksum = nextproto6_cksum(ip6, bp, len, len, IPPROTO_PIM); return (cksum ? INCORRECT : CORRECT); +#endif } else { return (UNVERIFIED); } @@ -785,8 +787,6 @@ pimv2_print(netdissect_options *ndo, if (ndo->ndo_vflag > 1) { const u_char *ptr = bp; while (ptr < (bp+olen)) { - int advance; - ND_PRINT((ndo, "\n\t ")); advance = pimv2_addr_print(ndo, ptr, pimv2_unicast, 0); if (advance < 0) {