summaryrefslogtreecommitdiff
path: root/print-timed.c
diff options
context:
space:
mode:
authorFrancois-Xavier Le Bail <devel.fx.lebail@orange.fr>2018-06-16 17:23:21 +0200
committerFrancois-Xavier Le Bail <devel.fx.lebail@orange.fr>2019-03-26 21:06:24 +0100
commitee68aa36460d7efeca48747f33b7f2adc0900bfb (patch)
tree72c1b65d29301835c0e064b433ea685fc856a68e /print-timed.c
parent1af20c3adc4dfef93de41d4fcd02f0aeb6bbfd4e (diff)
downloadtcpdump-ee68aa36460d7efeca48747f33b7f2adc0900bfb.tar.gz
Use the new GET_ macros instead of the EXTRACT_ ones
The exceptions are currently: Some EXTRACT_ in print-juniper.c, not used on packet buffer pointer. An EXTRACT_BE_U_3 in addrtoname.c, not always used on packet buffer pointer.
Diffstat (limited to 'print-timed.c')
-rw-r--r--print-timed.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/print-timed.c b/print-timed.c
index f9a5835a..819f0161 100644
--- a/print-timed.c
+++ b/print-timed.c
@@ -99,30 +99,30 @@ timed_print(netdissect_options *ndo,
ndo->ndo_protocol = "timed";
ND_TCHECK_1(tsp->tsp_type);
- tsp_type = EXTRACT_U_1(tsp->tsp_type);
+ tsp_type = GET_U_1(tsp->tsp_type);
if (tsp_type < TSPTYPENUMBER)
ND_PRINT("TSP_%s", tsptype[tsp_type]);
else
ND_PRINT("(tsp_type %#x)", tsp_type);
ND_TCHECK_1(tsp->tsp_vers);
- ND_PRINT(" vers %u", EXTRACT_U_1(tsp->tsp_vers));
+ ND_PRINT(" vers %u", GET_U_1(tsp->tsp_vers));
ND_TCHECK_2(tsp->tsp_seq);
- ND_PRINT(" seq %u", EXTRACT_BE_U_2(tsp->tsp_seq));
+ ND_PRINT(" seq %u", GET_BE_U_2(tsp->tsp_seq));
switch (tsp_type) {
case TSP_LOOP:
ND_TCHECK_1(tsp->tsp_hopcnt);
- ND_PRINT(" hopcnt %u", EXTRACT_U_1(tsp->tsp_hopcnt));
+ ND_PRINT(" hopcnt %u", GET_U_1(tsp->tsp_hopcnt));
break;
case TSP_SETTIME:
case TSP_ADJTIME:
case TSP_SETDATE:
case TSP_SETDATEREQ:
ND_TCHECK_8(&tsp->tsp_time);
- sec = EXTRACT_BE_S_4(tsp->tsp_time.tv_sec);
- usec = EXTRACT_BE_S_4(tsp->tsp_time.tv_usec);
+ sec = GET_BE_S_4(tsp->tsp_time.tv_sec);
+ usec = GET_BE_S_4(tsp->tsp_time.tv_usec);
/* XXX The comparison below is always false? */
if (usec < 0)
/* invalid, skip the rest of the packet */