Fix nil pointer dereference in `main.startCollectingStats`
This commit is contained in:
parent
134d01fcc1
commit
b8eaffb0f6
|
@ -173,9 +173,11 @@ func startCollectingStats(interruptCh <-chan struct{}, nodeManager common.NodeMa
|
||||||
|
|
||||||
<-interruptCh
|
<-interruptCh
|
||||||
|
|
||||||
|
if server != nil {
|
||||||
if err := server.Shutdown(context.TODO()); err != nil {
|
if err := server.Shutdown(context.TODO()); err != nil {
|
||||||
log.Printf("Failed to shutdown metrics server: %v", err)
|
log.Printf("Failed to shutdown metrics server: %v", err)
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// makeNodeConfig parses incoming CLI options and returns node configuration object
|
// makeNodeConfig parses incoming CLI options and returns node configuration object
|
||||||
|
|
Loading…
Reference in New Issue