summaryrefslogtreecommitdiff
path: root/ospf6d/ospf6_interface.c
diff options
context:
space:
mode:
authorRafael Zalamena <rzalamena@opensourcerouting.org>2019-01-23 10:06:49 -0200
committerRafael Zalamena <rzalamena@opensourcerouting.org>2019-01-23 10:06:49 -0200
commit849576ee962518c926c6a264a497e873210941e8 (patch)
tree92adc1830573e66a6cc57a3494a61bf0f16bd100 /ospf6d/ospf6_interface.c
parentb3cfe1e2da00c3a0233885d83d7d7246291c8e40 (diff)
ospf6d: don't queue interface events
Apply interface event as soon as possible instead of queueing an event for it. Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
Diffstat (limited to 'ospf6d/ospf6_interface.c')
-rw-r--r--ospf6d/ospf6_interface.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/ospf6d/ospf6_interface.c b/ospf6d/ospf6_interface.c
index 2bfa4201cb..3189269810 100644
--- a/ospf6d/ospf6_interface.c
+++ b/ospf6d/ospf6_interface.c
@@ -381,9 +381,9 @@ void ospf6_interface_state_update(struct interface *ifp)
if (if_is_operative(ifp)
&& (ospf6_interface_get_linklocal_address(oi->interface)
|| if_is_loopback(oi->interface)))
- thread_add_event(master, interface_up, oi, 0, NULL);
+ thread_execute(master, interface_up, oi, 0);
else
- thread_add_event(master, interface_down, oi, 0, NULL);
+ thread_execute(master, interface_down, oi, 0);
return;
}
@@ -1791,8 +1791,8 @@ DEFUN (ipv6_ospf6_network,
}
/* Reset the interface */
- thread_add_event(master, interface_down, oi, 0, NULL);
- thread_add_event(master, interface_up, oi, 0, NULL);
+ thread_execute(master, interface_down, oi, 0);
+ thread_execute(master, interface_up, oi, 0);
return CMD_SUCCESS;
}
@@ -1825,8 +1825,8 @@ DEFUN (no_ipv6_ospf6_network,
oi->type = type;
/* Reset the interface */
- thread_add_event(master, interface_down, oi, 0, NULL);
- thread_add_event(master, interface_up, oi, 0, NULL);
+ thread_execute(master, interface_down, oi, 0);
+ thread_execute(master, interface_up, oi, 0);
return CMD_SUCCESS;
}
@@ -1969,8 +1969,8 @@ static void ospf6_interface_clear(struct vty *vty, struct interface *ifp)
zlog_debug("Interface %s: clear by reset", ifp->name);
/* Reset the interface */
- thread_add_event(master, interface_down, oi, 0, NULL);
- thread_add_event(master, interface_up, oi, 0, NULL);
+ thread_execute(master, interface_down, oi, 0);
+ thread_execute(master, interface_up, oi, 0);
}
/* Clear interface */