diff options
Diffstat (limited to 'cmd/gobgpd/main.go')
-rw-r--r-- | cmd/gobgpd/main.go | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/cmd/gobgpd/main.go b/cmd/gobgpd/main.go index 0e288461..e8d9df4b 100644 --- a/cmd/gobgpd/main.go +++ b/cmd/gobgpd/main.go @@ -474,6 +474,8 @@ func main() { loop := func() { var c *config.BgpConfigSet + initialConfig := <-configCh + c = applyInitialConfig(bgpServer, initialConfig, opts.GracefulRestart) for { select { case <-sigCh: @@ -483,11 +485,7 @@ func main() { } return case newConfig := <-configCh: - if c == nil { - c = applyInitialConfig(bgpServer, newConfig, opts.GracefulRestart) - } else { - c = updateConfig(bgpServer, c, newConfig) - } + c = updateConfig(bgpServer, c, newConfig) } } } |