From ce19a04aea80f45ca1da80e28bf3a1253138c691 Mon Sep 17 00:00:00 2001 From: David Lamparter Date: Tue, 8 Aug 2017 10:50:43 +0200 Subject: lib: replace if_add_hook with hook_* logic This allows modules to register their own additional hooks on interface creation/deletion. Signed-off-by: David Lamparter --- zebra/interface.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'zebra/interface.c') diff --git a/zebra/interface.c b/zebra/interface.c index c4d0363994..48158c82c4 100644 --- a/zebra/interface.c +++ b/zebra/interface.c @@ -2930,8 +2930,8 @@ static int if_config_write(struct vty *vty) void zebra_if_init(void) { /* Initialize interface and new hook. */ - if_add_hook(IF_NEW_HOOK, if_zebra_new_hook); - if_add_hook(IF_DELETE_HOOK, if_zebra_delete_hook); + hook_register_prio(if_add, 0, if_zebra_new_hook); + hook_register_prio(if_del, 0, if_zebra_delete_hook); /* Install configuration write function. */ install_node(&interface_node, if_config_write); -- cgit v1.2.3