diff options
author | Francois-Xavier Le Bail <devel.fx.lebail@orange.fr> | 2019-04-02 15:28:54 +0200 |
---|---|---|
committer | Francois-Xavier Le Bail <devel.fx.lebail@orange.fr> | 2019-04-02 15:38:43 +0200 |
commit | dec3c3e848b473a81c9e4872ac11914d70e04d91 (patch) | |
tree | b7591b55ec10d46f31383fb5d1917e1de55c0ddd /print-ospf6.c | |
parent | 89c54d9bdade4e98c94ecd1c4f74593f6c7f3ce7 (diff) | |
download | tcpdump-dec3c3e848b473a81c9e4872ac11914d70e04d91.tar.gz |
OSPFv3: Add/remove some bounds checks
Remove two bounds checks now useless with GET_ macros uses.
The check on 'lshp->ls_router' is needed before ipaddr_string() call.
Diffstat (limited to 'print-ospf6.c')
-rw-r--r-- | print-ospf6.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/print-ospf6.c b/print-ospf6.c index c734b4d2..cec67e1d 100644 --- a/print-ospf6.c +++ b/print-ospf6.c @@ -388,8 +388,7 @@ ospf6_print_lshdr(netdissect_options *ndo, { if ((const u_char *)(lshp + 1) > dataend) goto trunc; - ND_TCHECK_2(lshp->ls_type); - ND_TCHECK_4(lshp->ls_seq); + ND_TCHECK_4(lshp->ls_router); ND_PRINT("\n\t Advertising Router %s, seq 0x%08x, age %us, length %u", ipaddr_string(ndo, lshp->ls_router), |