]> The Tcpdump Group git mirrors - tcpdump/blobdiff - print-m3ua.c
ICMPv6: Add the IPv6-Only flag
[tcpdump] / print-m3ua.c
index 799966461dbb30cb2b001aba1083fecf037885e6..7e2b0c8cc012bfbc6762b87d65667fb2d84fda32 100644 (file)
@@ -35,7 +35,6 @@
 #include "netdissect.h"
 #include "extract.h"
 
-static const char tstr[] = " [|m3ua]";
 
 #define M3UA_REL_1_0 1
 
@@ -230,11 +229,11 @@ tag_value_print(netdissect_options *ndo,
   return;
 
 invalid:
-  ND_PRINT("%s", istr);
+  nd_print_invalid(ndo);
   ND_TCHECK_LEN(buf, size);
   return;
 trunc:
-  ND_PRINT("%s", tstr);
+  nd_print_trunc(ndo);
 }
 
 /*
@@ -278,11 +277,11 @@ m3ua_tags_print(netdissect_options *ndo,
   return;
 
 invalid:
-  ND_PRINT("%s", istr);
+  nd_print_invalid(ndo);
   ND_TCHECK_LEN(buf, size);
   return;
 trunc:
-  ND_PRINT("%s", tstr);
+  nd_print_trunc(ndo);
 }
 
 /*
@@ -304,6 +303,7 @@ m3ua_print(netdissect_options *ndo,
   const struct tok *dict;
   uint8_t msg_class;
 
+  ndo->ndo_protocol = "m3ua";
   /* size includes the header */
   if (size < sizeof(struct m3ua_common_header))
     goto invalid;
@@ -333,10 +333,10 @@ m3ua_print(netdissect_options *ndo,
   return;
 
 invalid:
-  ND_PRINT("%s", istr);
+  nd_print_invalid(ndo);
   ND_TCHECK_LEN(buf, size);
   return;
 trunc:
-  ND_PRINT("%s", tstr);
+  nd_print_trunc(ndo);
 }