[packages] quagga: Fix package download URL (#12425)
[feed/routing.git] / patches / 006-fix-no-ipv6.patch
1 --- a/zebra/main.c
2 +++ b/zebra/main.c
3 @@ -327,7 +327,9 @@ main (int argc, char **argv)
4 zebra_vty_init ();
5 access_list_init ();
6 prefix_list_init ();
7 +#ifdef RTADV
8 rtadv_init ();
9 +#endif
10 #ifdef HAVE_IRDP
11 irdp_init();
12 #endif
13 --- a/zebra/rtadv.h
14 +++ b/zebra/rtadv.h
15 @@ -26,6 +26,9 @@
16 #include "vty.h"
17 #include "zebra/interface.h"
18
19 +/* NB: RTADV is defined in zebra/interface.h above */
20 +#ifdef RTADV
21 +
22 /* Router advertisement prefix. */
23 struct rtadv_prefix
24 {
25 @@ -96,4 +99,6 @@ struct nd_opt_homeagent_info { /* Home
26
27 extern const char *rtadv_pref_strs[];
28
29 +#endif /* RTADV */
30 +
31 #endif /* _ZEBRA_RTADV_H */
32 --- a/zebra/zebra_vty.c
33 +++ b/zebra/zebra_vty.c
34 @@ -1197,6 +1197,40 @@ DEFUN (show_ip_protocol,
35 return CMD_SUCCESS;
36 }
37
38 +/*
39 + * Show IP mroute command to dump the BGP Multicast
40 + * routing table
41 + */
42 +DEFUN (show_ip_mroute,
43 + show_ip_mroute_cmd,
44 + "show ip mroute",
45 + SHOW_STR
46 + IP_STR
47 + "IP Multicast routing table\n")
48 +{
49 + struct route_table *table;
50 + struct route_node *rn;
51 + struct rib *rib;
52 + int first = 1;
53 +
54 + table = vrf_table (AFI_IP, SAFI_MULTICAST, 0);
55 + if (! table)
56 + return CMD_SUCCESS;
57 +
58 + /* Show all IPv4 routes. */
59 + for (rn = route_top (table); rn; rn = route_next (rn))
60 + for (rib = rn->info; rib; rib = rib->next)
61 + {
62 + if (first)
63 + {
64 + vty_out (vty, SHOW_ROUTE_V4_HEADER);
65 + first = 0;
66 + }
67 + vty_show_ip_route (vty, rn, rib);
68 + }
69 + return CMD_SUCCESS;
70 +}
71 +
72 \f
73 #ifdef HAVE_IPV6
74 /* General fucntion for IPv6 static route. */
75 @@ -1952,40 +1986,6 @@ DEFUN (show_ipv6_route_summary,
76 }
77
78 /*
79 - * Show IP mroute command to dump the BGP Multicast
80 - * routing table
81 - */
82 -DEFUN (show_ip_mroute,
83 - show_ip_mroute_cmd,
84 - "show ip mroute",
85 - SHOW_STR
86 - IP_STR
87 - "IP Multicast routing table\n")
88 -{
89 - struct route_table *table;
90 - struct route_node *rn;
91 - struct rib *rib;
92 - int first = 1;
93 -
94 - table = vrf_table (AFI_IP, SAFI_MULTICAST, 0);
95 - if (! table)
96 - return CMD_SUCCESS;
97 -
98 - /* Show all IPv4 routes. */
99 - for (rn = route_top (table); rn; rn = route_next (rn))
100 - for (rib = rn->info; rib; rib = rib->next)
101 - {
102 - if (first)
103 - {
104 - vty_out (vty, SHOW_ROUTE_V4_HEADER);
105 - first = 0;
106 - }
107 - vty_show_ip_route (vty, rn, rib);
108 - }
109 - return CMD_SUCCESS;
110 -}
111 -
112 -/*
113 * Show IPv6 mroute command.Used to dump
114 * the Multicast routing table.
115 */
116 @@ -2020,11 +2020,6 @@ DEFUN (show_ipv6_mroute,
117 return CMD_SUCCESS;
118 }
119
120 -
121 -
122 -
123 -
124 -
125 /* Write IPv6 static route configuration. */
126 static int
127 static_config_ipv6 (struct vty *vty)