]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Nest: Prevent withdraws from propagation back to source protocol (for accepted mode)
authorOndrej Zajicek (work) <santiago@crfreenet.org>
Tue, 19 Feb 2019 15:21:52 +0000 (16:21 +0100)
committerOndrej Zajicek (work) <santiago@crfreenet.org>
Tue, 19 Feb 2019 15:21:52 +0000 (16:21 +0100)
Update for one of previous patches, handles the the issue for
first-accepted mode of route propagation.

nest/rt-table.c

index 68ee59b4c5116ae8060d0ffe2f0beef966f1aa68..e06563f6364f486afe1b78a2b26bda8775808b9c 100644 (file)
@@ -484,7 +484,7 @@ rt_notify_basic(struct announce_hook *ah, net *net, rte *new0, rte *old0, int re
 static void
 rt_notify_accepted(struct announce_hook *ah, net *net, rte *new_changed, rte *old_changed, rte *before_old, int feed)
 {
-  // struct proto *p = ah->proto;
+  struct proto *p = ah->proto;
   struct proto_stats *stats = ah->stats;
 
   rte *r;
@@ -563,7 +563,9 @@ rt_notify_accepted(struct announce_hook *ah, net *net, rte *new_changed, rte *ol
    */
 
   /* Hack for changed filters */
-  if (old_changed && (old_changed->lastmod <= ah->last_out_filter_change))
+  if (old_changed &&
+      (p != old_changed->sender->proto) &&
+      (old_changed->lastmod <= ah->last_out_filter_change))
     {
       old_best = old_changed;
       goto found;