That way, if we don't have a full PKTAP header, we don't print anything
in the -x/-X hex dump or -A ASCII dump (but do print it with
-xx/-XX/-AA).
ndo->ndo_protocol = "pktap_if";
if (caplen < sizeof(pktap_header_t) || length < sizeof(pktap_header_t)) {
ND_PRINT("[|pktap]");
- return (0);
+ return (caplen);
}
hdr = (const pktap_header_t *)p;
dlt = EXTRACT_LE_U_4(hdr->pkt_dlt);
* be expanded in the future)?
*/
ND_PRINT("[|pktap]");
- return (0);
+ return (caplen);
}
if (caplen < hdrlen || length < hdrlen) {
ND_PRINT("[|pktap]");
- return (hdrlen);
+ return (caplen);
}
if (ndo->ndo_eflag)