From 6192f9020000a8e1d581a3f92c206189a033bf39 Mon Sep 17 00:00:00 2001 From: wanghonghao Date: Thu, 28 Jun 2018 17:55:11 +0800 Subject: config: Copy afi-safi objects from peer group to neighbor instead of share the same array --- config/default.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'config') diff --git a/config/default.go b/config/default.go index cbb11167..afe9af42 100644 --- a/config/default.go +++ b/config/default.go @@ -496,7 +496,9 @@ func OverwriteNeighborConfigWithPeerGroup(c *Neighbor, pg *PeerGroup) error { overwriteConfig(&c.TtlSecurity.Config, &pg.TtlSecurity.Config, "neighbor.ttl-security.config", v) if !v.IsSet("neighbor.afi-safis") { - c.AfiSafis = pg.AfiSafis + for _, afiSafi := range pg.AfiSafis { + c.AfiSafis = append(c.AfiSafis, afiSafi) + } } return nil -- cgit v1.2.3