Adjust ipfw_iface_{init,destroy}() definitions to avoid clang 15 warning

With clang 15, the following -Werror warnings are produced:

    sys/netpfil/ipfw/ip_fw_iface.c:206:16: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
    ipfw_iface_init()
                   ^
                    void
    sys/netpfil/ipfw/ip_fw_iface.c:219:19: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
    ipfw_iface_destroy()
                      ^
                       void

This is because ipfw_iface_init() and ipfw_iface_destroy() are declared
with (void) argument lists, but defined with empty argument lists. Make
the definitions match the declarations.

MFC after:	3 days
This commit is contained in:
Dimitry Andric 2022-07-21 21:37:09 +02:00
parent 4100dc46c7
commit 1eea6b9097

View File

@ -203,7 +203,7 @@ ipfw_kiflookup(char *name)
* mutex init.
*/
int
ipfw_iface_init()
ipfw_iface_init(void)
{
mtx_init(&vnet_mtx, "IPFW ifhandler mtx", NULL, MTX_DEF);
@ -216,7 +216,7 @@ ipfw_iface_init()
* Unregister khandlers iff init has been done.
*/
void
ipfw_iface_destroy()
ipfw_iface_destroy(void)
{
IPFW_DEL_SOPT_HANDLER(1, scodes);