summaryrefslogtreecommitdiff
path: root/zebra/zebra_rib.c
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2018-02-13 21:30:03 -0500
committerDonald Sharp <sharpd@cumulusnetworks.com>2018-02-23 14:45:57 -0500
commit9a9f89267a4aaf2904673b204a21e05e0832bbef (patch)
tree83e36c94789a73c3383256e384a70ddf4091aef8 /zebra/zebra_rib.c
parenteaa23e020fdd139639a060e924f3a524d8f50393 (diff)
zebra: Fix situation where we would notify the owner it lost due to admin distance
The 'struct route_entry *old' and 'struct route_entry *new' can sometimes be the same route type( for a route replace ), so when we are checking to see if a new owner has taken over, don't tell the owner it is replacing it self. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com.
Diffstat (limited to 'zebra/zebra_rib.c')
-rw-r--r--zebra/zebra_rib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/zebra/zebra_rib.c b/zebra/zebra_rib.c
index 1ba85f0ea2..82b92ae0dd 100644
--- a/zebra/zebra_rib.c
+++ b/zebra/zebra_rib.c
@@ -1110,7 +1110,7 @@ void rib_install_kernel(struct route_node *rn, struct route_entry *re,
* If this is a replace to a new RE let the originator of the RE
* know that they've lost
*/
- if (old && old != re)
+ if (old && (old != re) && (old->type != re->type))
zsend_route_notify_owner(old, p, ZAPI_ROUTE_BETTER_ADMIN_WON);
/*