From 933ec5f2362be30ceafbe7ced1f442343078ac4b Mon Sep 17 00:00:00 2001 From: hasso Date: Sun, 15 Aug 2004 05:52:07 +0000 Subject: SVN revisions 916-920 from Zebra. ABR support is almost done. --- ospf6d/ospf6_spf.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'ospf6d/ospf6_spf.c') diff --git a/ospf6d/ospf6_spf.c b/ospf6d/ospf6_spf.c index 285d4bbb..d3c0f816 100644 --- a/ospf6d/ospf6_spf.c +++ b/ospf6d/ospf6_spf.c @@ -342,8 +342,11 @@ ospf6_spf_install (struct ospf6_vertex *v, /* There should be no case where candidate being installed (variable "v") is closer than the one in the SPF tree (variable "route"). - In the case something's gone wrong with the behavior of + In the case something has gone wrong with the behavior of Priority-Queue. */ + + /* the case where the route exists already is handled and returned + up to here. */ assert (route == NULL); route = ospf6_route_create (); @@ -387,6 +390,8 @@ ospf6_spf_table_finish (struct ospf6_route_table *result_table) } } +/* RFC2328 16.1. Calculating the shortest-path tree for an area */ +/* RFC2740 3.8.1. Calculating the shortest path tree for an area */ void ospf6_spf_calculation (u_int32_t router_id, struct ospf6_route_table *result_table, @@ -415,7 +420,7 @@ ospf6_spf_calculation (u_int32_t router_id, root->area = oa; root->cost = 0; root->hops = 0; - root->nexthop[0].ifindex = 0; /* should have been loopbak I/F ... */ + root->nexthop[0].ifindex = 0; /* loopbak I/F is better ... */ inet_pton (AF_INET6, "::1", &root->nexthop[0].address); /* Actually insert root to the candidate-list as the only candidate */ @@ -427,7 +432,7 @@ ospf6_spf_calculation (u_int32_t router_id, /* get closest candidate from priority queue */ v = pqueue_dequeue (candidate_list); - /* install may result in merging and rejecting of the vertex */ + /* installing may result in merging or rejecting of the vertex */ if (ospf6_spf_install (v, result_table) < 0) continue; @@ -507,7 +512,7 @@ ospf6_spf_calculation_thread (struct thread *t) } ospf6_intra_route_calculation (oa); - ospf6_intra_asbr_calculation (oa); + ospf6_intra_brouter_calculation (oa); return 0; } -- cgit v1.2.3