]> The Tcpdump Group git mirrors - tcpdump/blobdiff - print-dtp.c
Add printing support for vsockmon devices.
[tcpdump] / print-dtp.c
index 004f7d317bd29a1a7221d89a2f1bb89f3965858d..1ea36fce52f3de14c5bd618c5c40c6f01fd2d484 100644 (file)
@@ -57,7 +57,7 @@ dtp_print(netdissect_options *ndo, const u_char *pptr, u_int length)
     ND_TCHECK_LEN(tptr, DTP_HEADER_LEN);
 
     ND_PRINT("DTPv%u, length %u",
-           EXTRACT_U_1(tptr),
+           GET_U_1(tptr),
            length);
 
     /*
@@ -72,8 +72,8 @@ dtp_print(netdissect_options *ndo, const u_char *pptr, u_int length)
     while (tptr < (pptr+length)) {
 
         ND_TCHECK_4(tptr);
-       type = EXTRACT_BE_U_2(tptr);
-        len  = EXTRACT_BE_U_2(tptr + 2);
+       type = GET_BE_U_2(tptr);
+        len  = GET_BE_U_2(tptr + 2);
        /* XXX: should not be but sometimes it is, see the test captures */
         if (type == 0)
             return;
@@ -96,7 +96,7 @@ dtp_print(netdissect_options *ndo, const u_char *pptr, u_int length)
        case DTP_DTP_TYPE_TLV:
                 if (len < 5)
                     goto invalid;
-                ND_PRINT(", 0x%x", EXTRACT_U_1(tptr + 4));
+                ND_PRINT(", 0x%x", GET_U_1(tptr + 4));
                 break;
 
        case DTP_NEIGHBOR_TLV: