summaryrefslogtreecommitdiffstats
path: root/proto/bgp
diff options
context:
space:
mode:
authorMartin Mares <mj@ucw.cz>2000-04-25 23:21:52 +0200
committerMartin Mares <mj@ucw.cz>2000-04-25 23:21:52 +0200
commit684c25d98fbfd7cc9275f401d8d451135615af8d (patch)
tree30e10ef9e5c89ba91d64250cd9777a94d2175a24 /proto/bgp
parentefcece2da3054d9a0e5b5d2233549b3323428023 (diff)
downloadbird-684c25d98fbfd7cc9275f401d8d451135615af8d.tar
bird-684c25d98fbfd7cc9275f401d8d451135615af8d.zip
When sending BGP attributes, re-create the flags, so that attributes
added by filters which get the flags wrong are fixed automagically.
Diffstat (limited to 'proto/bgp')
-rw-r--r--proto/bgp/attrs.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/proto/bgp/attrs.c b/proto/bgp/attrs.c
index 8bf730b..c229239 100644
--- a/proto/bgp/attrs.c
+++ b/proto/bgp/attrs.c
@@ -372,6 +372,8 @@ bgp_get_bucket(struct bgp_proto *p, ea_list *old, ea_list *tmp, int originate)
{
if (!bgp_attr_table[code].allow_in_ebgp && !p->is_internal)
continue;
+ /* The flags might have been zero if the attr was added by filters */
+ a->flags = (a->flags & BAF_PARTIAL) | bgp_attr_table[code].expected_flags;
}
if (code < 32)
seen |= 1 << code;