summaryrefslogtreecommitdiff
path: root/print-ah.c
diff options
context:
space:
mode:
authorFrancois-Xavier Le Bail <devel.fx.lebail@orange.fr>2018-05-18 11:14:27 +0200
committerFrancois-Xavier Le Bail <devel.fx.lebail@orange.fr>2018-05-18 11:16:21 +0200
commita1042c21e59c1543dba39a895a597f5d9e5b2572 (patch)
treec6dcb8f73dac1c51f4aa6fc9ed58788cbb5a94ad /print-ah.c
parent95e10b20266d982dd1ee978f47b8fe17fbfee475 (diff)
downloadtcpdump-a1042c21e59c1543dba39a895a597f5d9e5b2572.tar.gz
Use more the nd_print_trunc() call
Update the output of a test accordingly.
Diffstat (limited to 'print-ah.c')
-rw-r--r--print-ah.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/print-ah.c b/print-ah.c
index 75baea2e..735226f6 100644
--- a/print-ah.c
+++ b/print-ah.c
@@ -52,10 +52,7 @@ ah_print(netdissect_options *ndo, const u_char *bp)
ND_PRINT(",sumlen=%u", sumlen);
ND_TCHECK_4(ah + 1);
ND_PRINT(",seq=0x%x", EXTRACT_BE_U_4(ah + 1));
- if (!ND_TTEST_LEN(bp, sizeof(struct ah) + sumlen)) {
- ND_PRINT("[truncated]):");
- return -1;
- }
+ ND_TCHECK_LEN(bp, sizeof(struct ah) + sumlen);
ND_PRINT("): ");
return sizeof(struct ah) + sumlen;