git: dbce131b8f40 - main - pfctl: match geticmpcodeby*()/print_fromto() prototypes to definitions

From: Kristof Provost <kp_at_FreeBSD.org>
Date: Sat, 22 Apr 2023 17:44:29 UTC
The branch main has been updated by kp:

URL: https://cgit.FreeBSD.org/src/commit/?id=dbce131b8f40dbd5997db130e59ed7736a79f680

commit dbce131b8f40dbd5997db130e59ed7736a79f680
Author:     Kristof Provost <kp@FreeBSD.org>
AuthorDate: 2023-04-21 13:13:19 +0000
Commit:     Kristof Provost <kp@FreeBSD.org>
CommitDate: 2023-04-22 17:43:56 +0000

    pfctl: match geticmpcodeby*()/print_fromto() prototypes to definitions
    
    The definitions use sa_family_t, not u_int8_t.
    
    Sponsored by:   Rubicon Communications, LLC ("Netgate")
---
 sbin/pfctl/pfctl_parser.c | 2 +-
 sbin/pfctl/pfctl_parser.h | 8 ++++----
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/sbin/pfctl/pfctl_parser.c b/sbin/pfctl/pfctl_parser.c
index 15ed8c29abd0..1f8627f5e246 100644
--- a/sbin/pfctl/pfctl_parser.c
+++ b/sbin/pfctl/pfctl_parser.c
@@ -71,7 +71,7 @@ void		 print_port (u_int8_t, u_int16_t, u_int16_t, const char *, int);
 void		 print_ugid (u_int8_t, unsigned, unsigned, const char *, unsigned);
 void		 print_flags (u_int8_t);
 void		 print_fromto(struct pf_rule_addr *, pf_osfp_t,
-		    struct pf_rule_addr *, u_int8_t, u_int8_t, int, int);
+		    struct pf_rule_addr *, sa_family_t, u_int8_t, int, int);
 int		 ifa_skip_if(const char *filter, struct node_host *p);
 
 struct node_host	*host_if(const char *, int, int *);
diff --git a/sbin/pfctl/pfctl_parser.h b/sbin/pfctl/pfctl_parser.h
index c5da3408fb93..563c525c1707 100644
--- a/sbin/pfctl/pfctl_parser.h
+++ b/sbin/pfctl/pfctl_parser.h
@@ -340,10 +340,10 @@ struct icmpcodeent {
 	u_int8_t code;
 };
 
-const struct icmptypeent *geticmptypebynumber(u_int8_t, u_int8_t);
-const struct icmptypeent *geticmptypebyname(char *, u_int8_t);
-const struct icmpcodeent *geticmpcodebynumber(u_int8_t, u_int8_t, u_int8_t);
-const struct icmpcodeent *geticmpcodebyname(u_long, char *, u_int8_t);
+const struct icmptypeent *geticmptypebynumber(u_int8_t, sa_family_t);
+const struct icmptypeent *geticmptypebyname(char *, sa_family_t);
+const struct icmpcodeent *geticmpcodebynumber(u_int8_t, u_int8_t, sa_family_t);
+const struct icmpcodeent *geticmpcodebyname(u_long, char *, sa_family_t);
 
 struct pf_timeout {
 	const char	*name;