From 22df2d8aaf537318425b9cdca9757bf58f98ecda Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Fri, 25 Oct 2019 20:37:26 -0400 Subject: [PATCH] bgpd: Logically dead code SAFI_EVPN and SAFI_MPLSVPN have been excluded by previous if statements. This code is dead. Signed-off-by: Donald Sharp --- bgpd/bgp_route.c | 20 +++++--------------- 1 file changed, 5 insertions(+), 15 deletions(-) diff --git a/bgpd/bgp_route.c b/bgpd/bgp_route.c index de4f185ab2..af73a3afc4 100644 --- a/bgpd/bgp_route.c +++ b/bgpd/bgp_route.c @@ -7241,21 +7241,11 @@ void route_vty_out(struct vty *vty, struct prefix *p, if (json_paths) { json_nexthop_global = json_object_new_object(); - if ((safi == SAFI_MPLS_VPN) || (safi == SAFI_EVPN)) - json_object_string_add( - json_nexthop_global, - nexthop_fqdn ? "fqdn" : "ip", - nexthop_fqdn - ? nexthop_fqdn - : inet_ntoa( - attr->mp_nexthop_global_in)); - else - json_object_string_add( - json_nexthop_global, - nexthop_fqdn ? "fqdn" : "ip", - nexthop_fqdn - ? nexthop_fqdn - : inet_ntoa(attr->nexthop)); + json_object_string_add(json_nexthop_global, + nexthop_fqdn ? "fqdn" : "ip", + nexthop_fqdn + ? nexthop_fqdn + : inet_ntoa(attr->nexthop)); json_object_string_add(json_nexthop_global, "afi", "ipv4"); -- 2.39.5