X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/ed85e20e4d6a27d5405f37366dd34b64c10a9211..ff1df423b6a8cda80cef88efa8a3162abcfd0e6e:/print-smb.c diff --git a/print-smb.c b/print-smb.c index 6bffa7cb..7330d6b5 100644 --- a/print-smb.c +++ b/print-smb.c @@ -6,16 +6,15 @@ * or later */ -#define NETDISSECT_REWORKED #ifdef HAVE_CONFIG_H #include "config.h" #endif -#include +#include #include -#include "interface.h" +#include "netdissect.h" #include "extract.h" #include "smb.h" @@ -1255,14 +1254,15 @@ smb_tcp_print(netdissect_options *ndo, if (smb_len >= 4 && caplen >= 4 && memcmp(data,"\377SMB",4) == 0) { if ((int)smb_len > caplen) { if ((int)smb_len > length) - ND_PRINT((ndo, "WARNING: Packet is continued in later TCP segments\n")); + ND_PRINT((ndo, " WARNING: Packet is continued in later TCP segments\n")); else - ND_PRINT((ndo, "WARNING: Short packet. Try increasing the snap length by %d\n", + ND_PRINT((ndo, " WARNING: Short packet. Try increasing the snap length by %d\n", smb_len - caplen)); - } + } else + ND_PRINT((ndo, " ")); print_smb(ndo, data, maxbuf > data + smb_len ? data + smb_len : maxbuf); } else - ND_PRINT((ndo, "SMB-over-TCP packet:(raw data or continuation?)\n")); + ND_PRINT((ndo, " SMB-over-TCP packet:(raw data or continuation?)\n")); return; trunc: ND_PRINT((ndo, "%s", tstr));