]> The Tcpdump Group git mirrors - tcpdump/commit
WB: Modernize packet parsing style.
authorDenis Ovsienko <[email protected]>
Sun, 11 Oct 2020 10:57:32 +0000 (11:57 +0100)
committerDenis Ovsienko <[email protected]>
Sun, 11 Oct 2020 11:27:20 +0000 (12:27 +0100)
commitd32231a35b587b74d599b7ba428705db3514e95e
tree0d2613f8072e0c214efb88dfc01a3906a792ba4d
parent1f336f66e19d1e207d43e9d5625329d628c495b3
WB: Modernize packet parsing style.

Enable ND_LONGJMP_FROM_TCHECK. Remove ND_TTEST*() instances that were
excess and convert the rest to ND_TCHECK*() with comments. Do not guard
ndo_snapend directly. Make sure that functions specific to message types
do not return on truncated data and return -1 when they have looked deep
enough to tell an invalid packet. In wb_print() deduplicate some code and
report invalid packets as invalid instead of truncated, also consider an
unknown packet type invalid. Update a test.
print-wb.c
tests/rsvp_uni-oobr-3.out