Skip to content

Commit

Permalink
UPSTREAM: <carry>: *: ensure zap logger is set before use
Browse files Browse the repository at this point in the history
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
  • Loading branch information
hexfusion authored and Elbehery committed Jul 12, 2022
1 parent 01742da commit c1c5f59
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion embed/etcd.go
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ func StartEtcd(inCfg *Config) (e *Etcd, err error) {
e = nil
}()

if !cfg.SocketOpts.Empty() {
if cfg.logger != nil && !cfg.SocketOpts.Empty() {
cfg.logger.Info(
"configuring socket options",
zap.Bool("reuse-address", cfg.SocketOpts.ReuseAddress),
Expand Down

0 comments on commit c1c5f59

Please sign in to comment.