diff options
Diffstat (limited to 'gobgpd/main.go')
-rw-r--r-- | gobgpd/main.go | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/gobgpd/main.go b/gobgpd/main.go index afdd71c9..fdfb8cca 100644 --- a/gobgpd/main.go +++ b/gobgpd/main.go @@ -178,21 +178,21 @@ func main() { log.Fatalf("failed to set collector config: %s", err) } } - for _, c := range newConfig.RpkiServers { - if err := bgpServer.AddRpki(&c.Config); err != nil { + for i, _ := range newConfig.RpkiServers { + if err := bgpServer.AddRpki(&newConfig.RpkiServers[i].Config); err != nil { log.Fatalf("failed to set rpki config: %s", err) } } - for _, c := range newConfig.BmpServers { - if err := bgpServer.AddBmp(&c.Config); err != nil { + for i, _ := range newConfig.BmpServers { + if err := bgpServer.AddBmp(&newConfig.BmpServers[i].Config); err != nil { log.Fatalf("failed to set bmp config: %s", err) } } - for _, c := range newConfig.MrtDump { - if len(c.Config.FileName) == 0 { + for i, _ := range newConfig.MrtDump { + if len(newConfig.MrtDump[i].Config.FileName) == 0 { continue } - if err := bgpServer.EnableMrt(&c.Config); err != nil { + if err := bgpServer.EnableMrt(&newConfig.MrtDump[i].Config); err != nil { log.Fatalf("failed to set mrt config: %s", err) } } |