X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/7b2c5a11a7bc236d72b440c4db5263edb23b4880..a9d6fee301938c5a1d2033bf8b8f09db19efca5b:/print-ppi.c diff --git a/print-ppi.c b/print-ppi.c index dde1cdb0..b9f76579 100644 --- a/print-ppi.c +++ b/print-ppi.c @@ -50,7 +50,7 @@ ppi_print(netdissect_options *ndo, const struct pcap_pkthdr *h, const u_char *p) { if_printer printer; - ppi_header_t *hdr; + const ppi_header_t *hdr; u_int caplen = h->caplen; u_int length = h->len; uint16_t len; @@ -62,7 +62,7 @@ ppi_print(netdissect_options *ndo, return (caplen); } - hdr = (ppi_header_t *)p; + hdr = (const ppi_header_t *)p; len = EXTRACT_LE_16BITS(&hdr->ppi_len); if (caplen < len) { /* @@ -89,7 +89,7 @@ ppi_print(netdissect_options *ndo, hdrlen = printer(ndo, h, p); } else { if (!ndo->ndo_eflag) - ppi_header_print(ndo, (u_char *)hdr, length + len); + ppi_header_print(ndo, (const u_char *)hdr, length + len); if (!ndo->ndo_suppress_default_print) ND_DEFAULTPRINT(p, caplen);