diff options
Diffstat (limited to 'config/serve.go')
-rw-r--r-- | config/serve.go | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/config/serve.go b/config/serve.go index c4aabdec..6832f6b4 100644 --- a/config/serve.go +++ b/config/serve.go @@ -11,10 +11,11 @@ func ReadConfigfileServe(path string, configCh chan Bgp, reloadCh chan bool) { b := Bgp{} md, err := toml.DecodeFile(path, &b) + if err == nil { + err = SetDefaultConfigValues(md, &b) + } if err != nil { - log.Fatal("can't read config file ", path, err) - } else { - SetDefaultConfigValues(md, &b) + log.Fatal("can't read config file ", path, ", ", err) } configCh <- b |