]> The Tcpdump Group git mirrors - tcpdump/commitdiff
Update tok2strbuf() to a static function
authorFrancois-Xavier Le Bail <[email protected]>
Tue, 18 Jan 2022 10:09:38 +0000 (11:09 +0100)
committerFrancois-Xavier Le Bail <[email protected]>
Tue, 18 Jan 2022 10:09:52 +0000 (11:09 +0100)
It is only used in util-print.c.

netdissect.h
util-print.c

index 89da451ebb84e7da2c907983bbe21c94e3849153..a10ffa3b6b566e765ed628f465cde1680dbf1a86 100644 (file)
@@ -141,9 +141,6 @@ struct tok {
        const char *s;          /* string */
 };
 
-extern const char *tok2strbuf(const struct tok *, const char *, u_int,
-                             char *buf, size_t bufsize);
-
 /* tok2str is deprecated */
 extern const char *tok2str(const struct tok *, const char *, u_int);
 extern char *bittok2str(const struct tok *, const char *, u_int);
index d65f026608a72a5b262d435a6b60b2736eddfdaa..a548b5ba3c50ceec7e8c950deef03497e13be89c 100644 (file)
@@ -470,7 +470,7 @@ print_unknown_data(netdissect_options *ndo, const u_char *cp,
 /*
  * Convert a token value to a string; use "fmt" if not found.
  */
-const char *
+static const char *
 tok2strbuf(const struct tok *lp, const char *fmt,
           u_int v, char *buf, size_t bufsize)
 {