From: Francois-Xavier Le Bail Date: Wed, 3 Apr 2019 18:59:41 +0000 (+0200) Subject: Ethernet: Rename a printer X-Git-Tag: tcpdump-4.99-bp~848 X-Git-Url: https://git.tcpdump.org/tcpdump/commitdiff_plain/cc82ffa44fabb75e4ea10033452699b389c57b8a Ethernet: Rename a printer Rename ether_print_hdr_len() to ether_hdr_len_print(), with _print suffix like in most similar cases. --- diff --git a/netdissect.h b/netdissect.h index 0912d418..debd3826 100644 --- a/netdissect.h +++ b/netdissect.h @@ -571,7 +571,7 @@ extern void egp_print(netdissect_options *, const u_char *, u_int); extern void eigrp_print(netdissect_options *, const u_char *, u_int); extern void esp_print(netdissect_options *, const u_char *, u_int, const u_char *, u_int, int, u_int); extern u_int ether_print(netdissect_options *, const u_char *, u_int, u_int, void (*)(netdissect_options *, const u_char *), const u_char *); -extern u_int ether_print_hdr_len(netdissect_options *, const u_char *, u_int, u_int, void (*)(netdissect_options *, const u_char *), const u_char *, u_int); +extern u_int ether_hdr_len_print(netdissect_options *, const u_char *, u_int, u_int, void (*)(netdissect_options *, const u_char *), const u_char *, u_int); extern int ethertype_print(netdissect_options *, u_short, const u_char *, u_int, u_int, const struct lladdr_info *, const struct lladdr_info *); extern u_int fddi_print(netdissect_options *, const u_char *, u_int, u_int); extern void forces_print(netdissect_options *, const u_char *, u_int); diff --git a/print-brcmtag.c b/print-brcmtag.c index d1882e51..06150f55 100644 --- a/print-brcmtag.c +++ b/print-brcmtag.c @@ -163,7 +163,7 @@ brcm_tag_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, * | MAC DA (6)|| MAC SA (6)||Broadcom tag (4)||Type/Length(2)| * +-----------++-----------++----------------++--------------+ */ - ret = ether_print_hdr_len(ndo, p, length, caplen, NULL, NULL, + ret = ether_hdr_len_print(ndo, p, length, caplen, NULL, NULL, ETHER_SA_OFFSET + BRCM_TAG_LEN + ETHER_TYPE_LEN); ndo->ndo_eflag = old_eflag; return ret; diff --git a/print-ether.c b/print-ether.c index 083d7ff7..8382e1ee 100644 --- a/print-ether.c +++ b/print-ether.c @@ -148,7 +148,7 @@ ether_hdr_print(netdissect_options *ndo, * FIXME: caplen can and should be derived from ndo->ndo_snapend and p. */ u_int -ether_print_hdr_len(netdissect_options *ndo, +ether_hdr_len_print(netdissect_options *ndo, const u_char *p, u_int length, u_int caplen, void (*print_encap_header)(netdissect_options *ndo, const u_char *), const u_char *encap_header_arg, u_int hdrlen) @@ -290,7 +290,7 @@ ether_print(netdissect_options *ndo, void (*print_encap_header)(netdissect_options *ndo, const u_char *), const u_char *encap_header_arg) { - return (ether_print_hdr_len(ndo, p, length, caplen, + return (ether_hdr_len_print(ndo, p, length, caplen, print_encap_header, encap_header_arg, ETHER_HDRLEN)); }