X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/ed85e20e4d6a27d5405f37366dd34b64c10a9211..ff1df423b6a8cda80cef88efa8a3162abcfd0e6e:/print-ipcomp.c diff --git a/print-ipcomp.c b/print-ipcomp.c index 1ba687e8..a6d25257 100644 --- a/print-ipcomp.c +++ b/print-ipcomp.c @@ -19,12 +19,11 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ -#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif -#include +#include struct ipcomp { uint8_t comp_nxt; /* Next Header */ @@ -36,7 +35,7 @@ struct ipcomp { #include #endif -#include "interface.h" +#include "netdissect.h" #include "extract.h" int @@ -49,13 +48,13 @@ ipcomp_print(netdissect_options *ndo, register const u_char *bp, int *nhdr _U_) int advance; #endif - ipcomp = (struct ipcomp *)bp; + ipcomp = (const struct ipcomp *)bp; cpi = EXTRACT_16BITS(&ipcomp->comp_cpi); /* 'ep' points to the end of available data. */ ep = ndo->ndo_snapend; - if ((u_char *)(ipcomp + 1) >= ep - sizeof(struct ipcomp)) { + if ((const u_char *)(ipcomp + 1) >= ep - sizeof(struct ipcomp)) { ND_PRINT((ndo, "[|IPCOMP]")); goto fail; }