]> The Tcpdump Group git mirrors - tcpdump/commitdiff
Don't set ndo_snaplen, either.
authorGuy Harris <[email protected]>
Sat, 3 Jun 2017 03:10:49 +0000 (20:10 -0700)
committerGuy Harris <[email protected]>
Sat, 3 Jun 2017 03:10:49 +0000 (20:10 -0700)
It's *not* the length of the captured data in the packet, it's the
snapshot length for the live capture or the savefile - the length of the
captured data in the packet could be less.

print-icmp.c

index 17e7a752cf6ec272e42c768b84104de8c0778f80..10772213e212f61075f5aadaaac02b001a2c845f 100644 (file)
@@ -580,7 +580,6 @@ icmp_print(netdissect_options *ndo, const u_char *bp, u_int plen, const u_char *
                bp += 8;
                ND_PRINT((ndo, "\n\t"));
                ip = (const struct ip *)bp;
-               ndo->ndo_snaplen = ndo->ndo_snapend - bp;
                 snapend_save = ndo->ndo_snapend;
                ip_print(ndo, bp, EXTRACT_16BITS(&ip->ip_len));
                 ndo->ndo_snapend = snapend_save;