]> The Tcpdump Group git mirrors - tcpdump/commitdiff
Use more the EXTRACT_8BITS() macro to fetch a one-byte value (13/n)
authorFrancois-Xavier Le Bail <[email protected]>
Mon, 20 Nov 2017 08:45:26 +0000 (09:45 +0100)
committerFrancois-Xavier Le Bail <[email protected]>
Mon, 20 Nov 2017 08:45:26 +0000 (09:45 +0100)
In ND_PRINT() macro calls (step 2).

print-ppp.c

index ba0fdc73263dcf3427b6890c4591c3b360464c93..88e5792d188ba505d3b65fc9d9924fdddc0b1a69 100644 (file)
@@ -434,8 +434,9 @@ handle_ctrl_proto(netdissect_options *ndo,
        ND_PRINT((ndo, "%s (0x%02x), id %u, length %u",
                  tok2str(cpcodes, "Unknown Opcode",code),
                  code,
-                 *tptr++, /* ID */
+                 EXTRACT_8BITS(tptr), /* ID */
                  length + 2));
+       tptr++;
 
        if (!ndo->ndo_vflag)
                return;