diff options
Diffstat (limited to 'bgpd/bgp_zebra.c')
-rw-r--r-- | bgpd/bgp_zebra.c | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/bgpd/bgp_zebra.c b/bgpd/bgp_zebra.c index 3d3bd90f5..8bc7bd302 100644 --- a/bgpd/bgp_zebra.c +++ b/bgpd/bgp_zebra.c @@ -698,7 +698,6 @@ zebra_read_ipv4 (int command, struct zclient *zclient, zebra_size_t length, return 0; } -#ifdef HAVE_IPV6 /* Zebra route add and delete treatment. */ static int zebra_read_ipv6 (int command, struct zclient *zclient, zebra_size_t length, @@ -817,7 +816,6 @@ zebra_read_ipv6 (int command, struct zclient *zclient, zebra_size_t length, return 0; } -#endif /* HAVE_IPV6 */ struct interface * if_lookup_by_ipv4 (struct in_addr *addr, vrf_id_t vrf_id) @@ -870,7 +868,6 @@ if_lookup_by_ipv4_exact (struct in_addr *addr, vrf_id_t vrf_id) return NULL; } -#ifdef HAVE_IPV6 struct interface * if_lookup_by_ipv6 (struct in6_addr *addr, ifindex_t ifindex, vrf_id_t vrf_id) { @@ -979,7 +976,6 @@ if_get_ipv6_local (struct interface *ifp, struct in6_addr *addr) } return 0; } -#endif /* HAVE_IPV6 */ static int if_get_ipv4_address (struct interface *ifp, struct in_addr *addr) @@ -1022,7 +1018,6 @@ bgp_nexthop_set (union sockunion *local, union sockunion *remote, else ifp = if_lookup_by_ipv4_exact (&local->sin.sin_addr, peer->bgp->vrf_id); } -#ifdef HAVE_IPV6 if (local->sa.sa_family == AF_INET6) { if (IN6_IS_ADDR_LINKLOCAL (&local->sin6.sin6_addr)) @@ -1037,7 +1032,6 @@ bgp_nexthop_set (union sockunion *local, union sockunion *remote, local->sin6.sin6_scope_id, peer->bgp->vrf_id); } -#endif /* HAVE_IPV6 */ if (!ifp) return -1; @@ -1047,7 +1041,6 @@ bgp_nexthop_set (union sockunion *local, union sockunion *remote, /* IPv4 connection, fetch and store IPv6 local address(es) if any. */ if (local->sa.sa_family == AF_INET) { -#ifdef HAVE_IPV6 /* IPv6 nexthop*/ ret = if_get_ipv6_global (ifp, &nexthop->v6_global); @@ -1069,10 +1062,8 @@ bgp_nexthop_set (union sockunion *local, union sockunion *remote, peer->shared_network = 1; else peer->shared_network = 0; -#endif /* HAVE_IPV6 */ } -#ifdef HAVE_IPV6 /* IPv6 connection, fetch and store IPv4 local address if any. */ if (local->sa.sa_family == AF_INET6) { @@ -1135,7 +1126,6 @@ bgp_nexthop_set (union sockunion *local, union sockunion *remote, SET_IN6_LINKLOCAL_IFINDEX (nexthop->v6_local, 0); } #endif /* KAME */ -#endif /* HAVE_IPV6 */ /* If we have identified the local interface, there is no error for now. */ return 0; @@ -1390,7 +1380,6 @@ bgp_zebra_announce (struct prefix *p, struct bgp_info *info, struct bgp *bgp, zapi_ipv4_route (valid_nh_count ? ZEBRA_IPV4_ROUTE_ADD: ZEBRA_IPV4_ROUTE_DELETE, zclient, (struct prefix_ipv4 *) p, &api); } -#ifdef HAVE_IPV6 /* We have to think about a IPv6 link-local address curse. */ if (p->family == AF_INET6 || @@ -1601,7 +1590,6 @@ bgp_zebra_announce (struct prefix *p, struct bgp_info *info, struct bgp *bgp, zclient, (struct prefix_ipv6 *) p, &api); } } -#endif /* HAVE_IPV6 */ } /* Announce all routes of a table to zebra */ @@ -1700,7 +1688,6 @@ bgp_zebra_withdraw (struct prefix *p, struct bgp_info *info, safi_t safi) zapi_ipv4_route (ZEBRA_IPV4_ROUTE_DELETE, zclient, (struct prefix_ipv4 *) p, &api); } -#ifdef HAVE_IPV6 /* We have to think about a IPv6 link-local address curse. */ if (p->family == AF_INET6) { @@ -1740,8 +1727,8 @@ bgp_zebra_withdraw (struct prefix *p, struct bgp_info *info, safi_t safi) zapi_ipv6_route (ZEBRA_IPV6_ROUTE_DELETE, zclient, (struct prefix_ipv6 *) p, &api); } -#endif /* HAVE_IPV6 */ } + struct bgp_redist * bgp_redist_lookup (struct bgp *bgp, afi_t afi, u_char type, u_short instance) { |