summaryrefslogtreecommitdiff
path: root/usr.sbin/bgpd/rde_decide.c
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2006-01-04 12:50:32 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2006-01-04 12:50:32 +0000
commit8579b500048ceec3057a0f2acbd6aa1762e1cfa9 (patch)
tree18cd7f4c9482e2ad02f860f73156f241f026fd2a /usr.sbin/bgpd/rde_decide.c
parent660a9a5d11e2039345b8cb7f1b8c06c7f6640a51 (diff)
If the decision process is turned of but a prefix is still active decrease the
active prefix counter.
Diffstat (limited to 'usr.sbin/bgpd/rde_decide.c')
-rw-r--r--usr.sbin/bgpd/rde_decide.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.sbin/bgpd/rde_decide.c b/usr.sbin/bgpd/rde_decide.c
index cea94a93fcf..a50b09717f4 100644
--- a/usr.sbin/bgpd/rde_decide.c
+++ b/usr.sbin/bgpd/rde_decide.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rde_decide.c,v 1.43 2005/11/29 21:11:07 claudio Exp $ */
+/* $OpenBSD: rde_decide.c,v 1.44 2006/01/04 12:50:31 claudio Exp $ */
/*
* Copyright (c) 2003, 2004 Claudio Jeker <claudio@openbsd.org>
@@ -208,8 +208,10 @@ prefix_evaluate(struct prefix *p, struct pt_entry *pte)
/* decision process is turned off */
if (p != NULL)
LIST_INSERT_HEAD(&pte->prefix_h, p, prefix_l);
- if (pte->active != NULL)
+ if (pte->active != NULL) {
+ pte->active->aspath->active_cnt--;
pte->active = NULL;
+ }
return;
}