summaryrefslogtreecommitdiff
path: root/usr.sbin/ospfd/kroute.c
diff options
context:
space:
mode:
authorMartin Pieuchot <mpi@cvs.openbsd.org>2015-07-18 15:57:15 +0000
committerMartin Pieuchot <mpi@cvs.openbsd.org>2015-07-18 15:57:15 +0000
commit157cfa18ebcb64477576ae720a776a46d8f7a188 (patch)
tree84772c86480b8ac8ab854a8c752b406d32a14983 /usr.sbin/ospfd/kroute.c
parent2271698f85393fb0d080c95f2232ce5bca8baf31 (diff)
Properly handle carp(4) interfaces in "backup" mode on start-up.
Problem analyzed and fix provided by Johan Ymerson, thanks! ok claudio@, benno@
Diffstat (limited to 'usr.sbin/ospfd/kroute.c')
-rw-r--r--usr.sbin/ospfd/kroute.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.sbin/ospfd/kroute.c b/usr.sbin/ospfd/kroute.c
index 1eb23cfadd6..32e40854225 100644
--- a/usr.sbin/ospfd/kroute.c
+++ b/usr.sbin/ospfd/kroute.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kroute.c,v 1.99 2015/07/17 20:06:46 claudio Exp $ */
+/* $OpenBSD: kroute.c,v 1.100 2015/07/18 15:57:14 mpi Exp $ */
/*
* Copyright (c) 2004 Esben Norby <norby@openbsd.org>
@@ -1019,6 +1019,9 @@ if_change(u_short ifindex, int flags, struct if_data *ifd,
return;
}
+ /* notify ospfe about interface link state */
+ main_imsg_compose_ospfe(IMSG_IFINFO, 0, kif, sizeof(struct kif));
+
reachable = (kif->flags & IFF_UP) &&
LINK_STATE_IS_UP(kif->link_state);
@@ -1027,9 +1030,6 @@ if_change(u_short ifindex, int flags, struct if_data *ifd,
kif->nh_reachable = reachable;
- /* notify ospfe about interface link state */
- main_imsg_compose_ospfe(IMSG_IFINFO, 0, kif, sizeof(struct kif));
-
/* update redistribute list */
RB_FOREACH(kr, kroute_tree, &krt) {
for (tkr = kr; tkr != NULL; tkr = tkr->next) {