The branch main has been updated by dim: URL: https://cgit.FreeBSD.org/src/commit/?id=d62830c5e493133b0212f39c7efdab4232f87abf
commit d62830c5e493133b0212f39c7efdab4232f87abf Author: Dimitry Andric <[email protected]> AuthorDate: 2022-07-21 19:30:05 +0000 Commit: Dimitry Andric <[email protected]> CommitDate: 2022-07-21 19:30:40 +0000 Adjust ipfw_{init,destroy}_sopt_handler() definitions to avoid clang 15 warning With clang 15, the following -Werror warning are produced: sys/netpfil/ipfw/ip_fw_sockopt.c:3477:23: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] ipfw_init_sopt_handler() ^ void sys/netpfil/ipfw/ip_fw_sockopt.c:3485:26: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes] ipfw_destroy_sopt_handler() ^ void This is because ipfw_init_sopt_handler() and ipfw_destroy_sopt_handler() are declared with (void) argument lists, but defined with empty argument lists. Make the definitions match the declarations. MFC after: 3 days --- sys/netpfil/ipfw/ip_fw_sockopt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/netpfil/ipfw/ip_fw_sockopt.c b/sys/netpfil/ipfw/ip_fw_sockopt.c index fd50df8dc412..e0d80a67827e 100644 --- a/sys/netpfil/ipfw/ip_fw_sockopt.c +++ b/sys/netpfil/ipfw/ip_fw_sockopt.c @@ -3474,7 +3474,7 @@ find_unref_sh(struct ipfw_sopt_handler *psh) } void -ipfw_init_sopt_handler() +ipfw_init_sopt_handler(void) { CTL3_LOCK_INIT(); @@ -3482,7 +3482,7 @@ ipfw_init_sopt_handler() } void -ipfw_destroy_sopt_handler() +ipfw_destroy_sopt_handler(void) { IPFW_DEL_SOPT_HANDLER(1, scodes);
