Merge pull request #2760 from donaldsharp/bgp_patch_from_dev

bgpd: Fix show ip bgp summary json command for dynamicPeers
This commit is contained in:
Russ White 2018-08-02 08:15:29 -04:00 committed by GitHub
commit 25f5f03987
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -7914,9 +7914,11 @@ static int bgp_show_summary(struct vty *vty, struct bgp *bgp, int afi, int safi,
if (use_json) {
json_peer = json_object_new_object();
if (peer_dynamic_neighbor(peer))
if (peer_dynamic_neighbor(peer)) {
dn_count++;
json_object_boolean_true_add(json_peer,
"dynamicPeer");
}
if (peer->hostname)
json_object_string_add(json_peer, "hostname",