https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=282870
Bug ID: 282870
Summary: rtnl_handle_iflink() has a type mismatch for
ifnet_link_event
Product: Base System
Version: Unspecified
Hardware: Any
OS: Any
Status: New
Severity: Affects Some People
Priority: ---
Component: kern
Assignee: [email protected]
Reporter: [email protected]
Created attachment 255318
--> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=255318&action=edit
patch for rtnl_handle_iflink type mismatch
In sys/net/if_var.h, the type for ifnet_link_event is defined as:
```
/* Interface link state change event */
typedef void (*ifnet_link_event_handler_t)(void *, if_t, int);
EVENTHANDLER_DECLARE(ifnet_link_event, ifnet_link_event_handler_t);
```
However, in sys/netlink/route/iface.c, the rtnl_handle_iflink() function, which
only takes two arguments, is registered as a handler for ifnet_link_event.
```
static void
rtnl_handle_iflink(void *arg, if_t ifp)
{
NL_LOG(LOG_DEBUG2, "ifnet %s", if_name(ifp));
rtnl_handle_ifevent(ifp, NL_RTM_NEWLINK, 0);
}
...
iflink_event = EVENTHANDLER_REGISTER(
ifnet_link_event, rtnl_handle_iflink, NULL,
EVENTHANDLER_PRI_ANY);
```
--
You are receiving this mail because:
You are the assignee for the bug.