diff options
| author | David Lamparter <equinox@opensourcerouting.org> | 2023-11-02 13:49:28 -0700 |
|---|---|---|
| committer | David Lamparter <equinox@opensourcerouting.org> | 2023-11-02 17:10:43 -0700 |
| commit | d889055d8e8d87cac0f4a7086e5b453bbe2d0f79 (patch) | |
| tree | 0fb96873f9b22943218f7c7d876839470370ca5f /pimd/pim_iface.c | |
| parent | 8e3a96e846a15f34384a20a3ede2e894d7e97253 (diff) | |
lib: convert if_zapi_callbacks into actual hooks
...so that multiple functions can be subscribed.
The create/destroy hooks are renamed to real/unreal because that's what
they *actually* signal.
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Diffstat (limited to 'pimd/pim_iface.c')
| -rw-r--r-- | pimd/pim_iface.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/pimd/pim_iface.c b/pimd/pim_iface.c index 5fa4715b05..e00a3c0f98 100644 --- a/pimd/pim_iface.c +++ b/pimd/pim_iface.c @@ -1771,8 +1771,10 @@ void pim_iface_init(void) hook_register_prio(if_add, 0, pim_if_new_hook); hook_register_prio(if_del, 0, pim_if_delete_hook); - if_zapi_callbacks(pim_ifp_create, pim_ifp_up, pim_ifp_down, - pim_ifp_destroy); + hook_register_prio(if_real, 0, pim_ifp_create); + hook_register_prio(if_up, 0, pim_ifp_up); + hook_register_prio(if_down, 0, pim_ifp_down); + hook_register_prio(if_unreal, 0, pim_ifp_destroy); } static void pim_if_membership_clear(struct interface *ifp) |
