Merge pull request #2519 from pacovn/Coverity_1399238_Logically_dead_code

bgpd: dead code (Coverity 1399238)
This commit is contained in:
Quentin Young 2018-06-21 14:20:48 -04:00 committed by GitHub
commit dfc5d40e91
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -6566,14 +6566,8 @@ void route_vty_out(struct vty *vty, struct prefix *p, struct bgp_info *binfo,
} else {
char buf[BUFSIZ];
if ((safi == SAFI_MPLS_VPN) || (safi == SAFI_EVPN))
snprintf(buf, sizeof(buf), "%s%s",
inet_ntoa(attr->mp_nexthop_global_in),
vrf_id_str);
else
snprintf(buf, sizeof(buf), "%s%s",
inet_ntoa(attr->nexthop),
vrf_id_str);
snprintf(buf, sizeof(buf), "%s%s",
inet_ntoa(attr->nexthop), vrf_id_str);
vty_out(vty, "%-16s", buf);
}
}