summaryrefslogtreecommitdiffhomepage
path: root/server/server.go
diff options
context:
space:
mode:
Diffstat (limited to 'server/server.go')
-rw-r--r--server/server.go7
1 files changed, 2 insertions, 5 deletions
diff --git a/server/server.go b/server/server.go
index e97fd7f6..0f113305 100644
--- a/server/server.go
+++ b/server/server.go
@@ -341,16 +341,13 @@ func filterpath(peer *Peer, path, old *table.Path) *table.Path {
}
if ignore {
-
- for _, adv := range peer.adjRibOut.PathList([]bgp.RouteFamily{path.GetRouteFamily()}, false) {
+ if old != nil {
// we advertise a route from ebgp,
// which is the old best. We got the
// new best from ibgp. We don't
// advertise the new best and need to
// withdraw the old.
- if path.GetNlri().String() == adv.GetNlri().String() {
- return adv.Clone(true)
- }
+ return old.Clone(true)
}
log.WithFields(log.Fields{
"Topic": "Peer",