1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
$NetBSD: patch-ch,v 1.1 2002/08/03 12:27:25 itojun Exp $
diff -u1 ospf6d/ospf6_route.c /home/itojun/work/zebra/zebra/ospf6d/ospf6_route.c
--- ospf6d/ospf6_route.c Sun Jul 7 17:12:48 2002
+++ /home/itojun/work/zebra/zebra/ospf6d/ospf6_route.c Sat Aug 3 21:06:12 2002
@@ -1015,2 +1015,6 @@
+ u_int route_count = 0;
+ u_int path_count = 0;
+ u_int route_redundant = 0;
+
memset (&prefix, 0, sizeof (struct prefix));
@@ -1103,3 +1107,5 @@
{
- if (! node->info)
+ struct ospf6_route_node *route = node->info;
+
+ if (! route)
continue;
@@ -1107,6 +1113,15 @@
if (detail)
- ospf6_route_show_detail (vty, node->info);
+ ospf6_route_show_detail (vty, route);
else
- ospf6_route_show (vty, node->info);
+ ospf6_route_show (vty, route);
+
+ route_count++;
+ path_count += route->path_list->count;
+ if (route->path_list->count > 1)
+ route_redundant++;
}
+
+ vty_out (vty, "===========%s", VTY_NEWLINE);
+ vty_out (vty, "Route: %d Path: %d Redundant: %d%s",
+ route_count, path_count, route_redundant, VTY_NEWLINE);
|