diff options
author | Ondrej Zajicek (work) <santiago@crfreenet.org> | 2019-02-19 16:21:52 +0100 |
---|---|---|
committer | Ondrej Zajicek (work) <santiago@crfreenet.org> | 2019-02-19 16:21:52 +0100 |
commit | b3fceeba30bd6a685de0aa17dbe6bcfd77d1ca29 (patch) | |
tree | 85b11b4f37c61c335eb7b86a62ff9e9e19227189 /nest | |
parent | 2dd9800ab51a309add1c56aa9659c41f30481299 (diff) |
Nest: Prevent withdraws from propagation back to source protocol (for accepted mode)
Update for one of previous patches, handles the the issue for
first-accepted mode of route propagation.
Diffstat (limited to 'nest')
-rw-r--r-- | nest/rt-table.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/nest/rt-table.c b/nest/rt-table.c index 68ee59b4..e06563f6 100644 --- a/nest/rt-table.c +++ b/nest/rt-table.c @@ -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; |