summaryrefslogtreecommitdiffstats
path: root/nest/rt-table.c
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2009-11-26 20:47:59 +0100
committerOndrej Zajicek <santiago@crfreenet.org>2009-11-26 20:47:59 +0100
commitbf47fe4b2e40ccfcfe6af2d86548d06cdf9739c5 (patch)
tree59108f1bdc8f5192a27e9a40d72a7e950686dd8c /nest/rt-table.c
parent5e6f568115511e2bcf43c60dfdcbd7a35cb04b93 (diff)
downloadbird-bf47fe4b2e40ccfcfe6af2d86548d06cdf9739c5.tar
bird-bf47fe4b2e40ccfcfe6af2d86548d06cdf9739c5.zip
Implements BGP route refresh.
Diffstat (limited to 'nest/rt-table.c')
-rw-r--r--nest/rt-table.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/nest/rt-table.c b/nest/rt-table.c
index dda0e56..e0cd797 100644
--- a/nest/rt-table.c
+++ b/nest/rt-table.c
@@ -199,6 +199,14 @@ do_rte_announce(struct announce_hook *a, int type, net *net, rte *new, rte *old,
else
p->stats.exp_withdraws_received++;
+ /* This is a tricky part - we don't know whether route 'old' was
+ exported to protocol 'p' or was filtered by the export filter.
+ We try tu run the export filter to know this to have a correct
+ value in 'old' argument of rt_update (and proper filter value)
+
+ FIXME - this is broken because 'configure soft' may change
+ filters but keep routes */
+
if (old)
{
if (p->out_filter == FILTER_REJECT)
@@ -216,6 +224,7 @@ do_rte_announce(struct announce_hook *a, int type, net *net, rte *new, rte *old,
}
}
+ /* FIXME - This is broken because of incorrect 'old' value (see above) */
if (!new && !old)
return;
@@ -1122,6 +1131,11 @@ rt_show_net(struct cli *c, net *n, struct rt_show_data *d)
ok = 0;
else if (!ic && d->export_mode > 1)
{
+ /* FIXME - this shows what should be exported according
+ to current filters, but not what was really exported.
+ 'configure soft' command may change the export filter
+ and do not update routes */
+
if (p1->out_filter == FILTER_REJECT ||
p1->out_filter && f_run(p1->out_filter, &e, &tmpa, rte_update_pool, FF_FORCE_TMPATTR) > F_ACCEPT)
ok = 0;