]> The Tcpdump Group git mirrors - tcpdump/blobdiff - print-smb.c
Fix printing of Linux cooked captures with monitor-mode packets.
[tcpdump] / print-smb.c
index 723b9a032415c00f1503db0b5334e13bdb301a80..5af01aea06d55eee4a4abce331ebc421cf9b6476 100644 (file)
@@ -940,7 +940,9 @@ nbt_tcp_print(netdissect_options *ndo,
     if (caplen < 4)
        goto trunc;
     maxbuf = data + caplen;
+    ND_TCHECK_8BITS(data);
     type = data[0];
+    ND_TCHECK_16BITS(data + 2);
     nbt_len = EXTRACT_16BITS(data + 2);
     length -= 4;
     caplen -= 4;