diff options
author | Ondrej Zajicek <santiago@crfreenet.org> | 2009-12-15 00:30:07 +0100 |
---|---|---|
committer | Ondrej Zajicek <santiago@crfreenet.org> | 2009-12-15 00:30:07 +0100 |
commit | f2d7da742bd683b8eaecb1be8e3b04618171c796 (patch) | |
tree | 7dc5020885bb4b3db426a23e077cc334b4ef2914 /proto/ospf | |
parent | 13a7395704deeeff2d86910d8bcf9a6f32a7b207 (diff) | |
download | bird-f2d7da742bd683b8eaecb1be8e3b04618171c796.tar bird-f2d7da742bd683b8eaecb1be8e3b04618171c796.zip |
Fixes export of routes with link-local gw.
Diffstat (limited to 'proto/ospf')
-rw-r--r-- | proto/ospf/topology.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/proto/ospf/topology.c b/proto/ospf/topology.c index 4665681..3ca5e77 100644 --- a/proto/ospf/topology.c +++ b/proto/ospf/topology.c @@ -899,12 +899,11 @@ originate_ext_lsa_body(net *n, rte *e, u16 *length, struct proto_ospf *po, int size = sizeof(struct ospf_lsa_ext); u32 *buf; - if (!ipa_equal(e->attrs->gw, IPA_NONE)) - { - /* FIXME: check for link-local in OSPFv3 ? */ - if (ospf_iface_find((struct proto_ospf *) p, e->attrs->iface) != NULL) - gw = 1; - } + if ((e->attrs->dest == RTD_ROUTER) && + !ipa_equal(e->attrs->gw, IPA_NONE) && + !ipa_has_link_scope(e->attrs->gw) && + (ospf_iface_find((struct proto_ospf *) p, e->attrs->iface) != NULL)) + gw = 1; #ifdef OSPFv3 size += IPV6_PREFIX_SPACE(n->n.pxlen); |