summaryrefslogtreecommitdiff
path: root/proto/ospf
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2010-05-21 16:40:09 +0200
committerOndrej Zajicek <santiago@crfreenet.org>2010-05-21 16:40:09 +0200
commit6d04ef8987f6f5483d353d393ef66dae4b887f30 (patch)
tree3ba591d5d96c279f0762d5970925ce5ef2562e3b /proto/ospf
parent87a9abeac976180ade1c7619545e610d743994b5 (diff)
Comment update.
Diffstat (limited to 'proto/ospf')
-rw-r--r--proto/ospf/rt.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/proto/ospf/rt.c b/proto/ospf/rt.c
index 8332ffad..944d0e53 100644
--- a/proto/ospf/rt.c
+++ b/proto/ospf/rt.c
@@ -340,7 +340,12 @@ ospf_rt_spfa_rtlinks(struct ospf_area *oa, struct top_hash_entry *act, struct to
{
#ifdef OSPFv2
case LSART_STUB:
- /* This violates RFC 2328! But it is mostly harmless. */
+ /*
+ * RFC 2328 in 16.1. (2a) says to handle stub networks in an
+ * second phase after the SPF for an area is calculated. We get
+ * the same result by handing them here because add_network()
+ * will keep the best (not the first) found route.
+ */
add_network(oa, ipa_from_u32(rtl->id),
ipa_mklen(ipa_from_u32(rtl->data)),
act->dist + rtl->metric, act);