summaryrefslogtreecommitdiff
path: root/usr.sbin/ospfd/interface.c
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2006-08-18 11:54:29 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2006-08-18 11:54:29 +0000
commitc22a8dffbeb4eaf5919433fbdf52f4c8d2968f20 (patch)
treebd21343fa1a79947a924dc8b9e0dc3779cfd1052 /usr.sbin/ospfd/interface.c
parent29eba4cded688b12e719a567c168567d0f95db63 (diff)
Correctly leave the all AllDRouters group (224.0.0.6) if the interface was
in state DR or BACKUP. Found while analizing PR5192 with norby@ -- seems to help but there is still a issue left. OK norby@
Diffstat (limited to 'usr.sbin/ospfd/interface.c')
-rw-r--r--usr.sbin/ospfd/interface.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/usr.sbin/ospfd/interface.c b/usr.sbin/ospfd/interface.c
index f18f93246a0..acac1d35b64 100644
--- a/usr.sbin/ospfd/interface.c
+++ b/usr.sbin/ospfd/interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: interface.c,v 1.51 2006/04/24 20:18:03 claudio Exp $ */
+/* $OpenBSD: interface.c,v 1.52 2006/08/18 11:54:28 claudio Exp $ */
/*
* Copyright (c) 2005 Claudio Jeker <claudio@openbsd.org>
@@ -563,6 +563,14 @@ if_act_reset(struct iface *iface)
log_warnx("if_act_reset: error leaving group %s, "
"interface %s", inet_ntoa(addr), iface->name);
}
+ if (iface->state & IF_STA_DRORBDR) {
+ inet_aton(AllDRouters, &addr);
+ if (if_leave_group(iface, &addr)) {
+ log_warnx("if_act_reset: "
+ "error leaving group %s, interface %s",
+ inet_ntoa(addr), iface->name);
+ }
+ }
break;
case IF_TYPE_VIRTUALLINK:
/* nothing */