diff options
author | Francois-Xavier Le Bail <devel.fx.lebail@orange.fr> | 2019-05-23 11:20:16 +0200 |
---|---|---|
committer | Francois-Xavier Le Bail <devel.fx.lebail@orange.fr> | 2019-05-23 11:23:37 +0200 |
commit | 0636ecf91357b749370170716e0c4cd494bcea84 (patch) | |
tree | c2f86b03c7f15fb990b922085fc022621398123c | |
parent | 20eab47a4d7d6acb7ef916f61f7db9ffb3d51ff9 (diff) | |
download | tcpdump-0636ecf91357b749370170716e0c4cd494bcea84.tar.gz |
Arista: Rename a printer
Rename arista_print_ethertype() to arista_ethertype_print(), with _print
suffix like in most similar cases.
Moreover:
Add a 'summary' comment with the protocol name.
-rw-r--r-- | netdissect.h | 2 | ||||
-rw-r--r-- | print-arista.c | 4 | ||||
-rw-r--r-- | print-ether.c | 2 |
3 files changed, 5 insertions, 3 deletions
diff --git a/netdissect.h b/netdissect.h index 37c07f13..020f58e4 100644 --- a/netdissect.h +++ b/netdissect.h @@ -566,7 +566,7 @@ extern int ah_print(netdissect_options *, const u_char *); extern void ahcp_print(netdissect_options *, const u_char *, const u_int); extern void aodv_print(netdissect_options *, const u_char *, u_int, int); extern void aoe_print(netdissect_options *, const u_char *, const u_int); -extern int arista_print_ethertype(netdissect_options *,const u_char *, u_int); +extern int arista_ethertype_print(netdissect_options *,const u_char *, u_int); extern void arp_print(netdissect_options *, const u_char *, u_int, u_int); extern void ascii_print(netdissect_options *, const u_char *, u_int); extern void atalk_print(netdissect_options *, const u_char *, u_int); diff --git a/print-arista.c b/print-arista.c index 38dd724a..ce0adc10 100644 --- a/print-arista.c +++ b/print-arista.c @@ -1,5 +1,7 @@ // Copyright (c) 2018 Arista Networks, Inc. All rights reserved. +/* \summary: EtherType protocol for Arista Networks printer */ + #ifdef HAVE_CONFIG_H #include "config.h" #endif @@ -19,7 +21,7 @@ #define ARISTA_TIMESTAMP_V2 0x20 int -arista_print_ethertype(netdissect_options *ndo, const u_char *bp, u_int len _U_) +arista_ethertype_print(netdissect_options *ndo, const u_char *bp, u_int len _U_) { uint16_t subTypeId; uint16_t version; diff --git a/print-ether.c b/print-ether.c index 4f8caa97..8899469b 100644 --- a/print-ether.c +++ b/print-ether.c @@ -314,7 +314,7 @@ recurse: } ether_type_print(ndo, length_type); ND_PRINT(", length %u: ", orig_length); - int bytesConsumed = arista_print_ethertype(ndo, p, length); + int bytesConsumed = arista_ethertype_print(ndo, p, length); if (bytesConsumed > 0) { p += bytesConsumed; length -= bytesConsumed; |