From: Francois-Xavier Le Bail Date: Tue, 18 Apr 2023 16:00:36 +0000 (+0200) Subject: RT6: Declare the struct tok srh_tlv_type "static" X-Git-Url: https://git.tcpdump.org/tcpdump/commitdiff_plain/c7fd6445c6c4c1b36183bc043a06a5e17237c49f RT6: Declare the struct tok srh_tlv_type "static" This should avoid error like: ./print-rt6.c:36:18: error: no previous extern declaration for non-static variable 'srh_tlv_type' [-Werror,-Wmissing-variable-declarations] const struct tok srh_tlv_type[] = { ^ ./print-rt6.c:36:7: note: declare 'static' if the variable is not intended to be used outside of this translation unit const struct tok srh_tlv_type[] = { ^ --- diff --git a/print-rt6.c b/print-rt6.c index 62db9a21..0478f382 100644 --- a/print-rt6.c +++ b/print-rt6.c @@ -33,7 +33,7 @@ #include "ip6.h" -const struct tok srh_tlv_type[] = { +static const struct tok srh_tlv_type[] = { { IPV6_SRH_TLV_PAD1, "Pad1"}, { IPV6_SRH_TLV_PADN, "PadN"}, { IPV6_SRH_TLV_HMAC, "HMAC"},