summaryrefslogtreecommitdiff
path: root/print.h
diff options
context:
space:
mode:
authorFrancois-Xavier Le Bail <devel.fx.lebail@orange.fr>2019-12-26 22:08:03 +0100
committerFrancois-Xavier Le Bail <devel.fx.lebail@orange.fr>2020-02-02 14:15:24 +0100
commit757e793ca521cbfdc4a6104c9a2a920f5538d195 (patch)
tree1cb5d5a01cc7d82363e0db3b6d52c56a326a6175 /print.h
parent4addcceb8068eacc3c69bdad6ba18ad58353c3a3 (diff)
downloadtcpdump-757e793ca521cbfdc4a6104c9a2a920f5538d195.tar.gz
Apply the first step of the new way to update the link-layer header length
Currently the return value of link-layer dissectors is supposed to be the length of the link-layer header, so that it can be skipped for -x and -X. If a link-layer dissector or a called function throws an exception, it returns no value, so that length isn't available. The goal is to change all the link-layer dissectors to be void functions and dissectors should update a new field of the netdissect_options structure "link-layer header length" rather than returning it as a value. In this transition process, the link-layer dissectors will be moved, when updated, from the uint_printers[] array (named before printers[]) to the void_printers[] array. In this transition process, a new field of the netdissect_options structure, ndo_void_printer (TRUE/FALSE), set in the updated function lookup_printer(), will permit to choose between the old and new way to update the link-layer header length.
Diffstat (limited to 'print.h')
-rw-r--r--print.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/print.h b/print.h
index 70ea9f8e..5e67b33a 100644
--- a/print.h
+++ b/print.h
@@ -32,7 +32,7 @@ void init_print(netdissect_options *ndo, uint32_t localnet, uint32_t mask);
int has_printer(int type);
-if_printer get_if_printer(netdissect_options *ndo, int type);
+if_printer_t get_if_printer(netdissect_options *ndo, int type);
void pretty_print_packet(netdissect_options *ndo,
const struct pcap_pkthdr *h, const u_char *sp,