Initialize nginx process error channel

goroutines that write to ngxErrCh remain asleep forever without that
necessary initialization.
This commit is contained in:
Antoine Cotten 2019-08-22 16:25:47 +02:00
parent 3166b985d9
commit d1feb65ff9
No known key found for this signature in database
GPG key ID: 94637E68D4A79DD0

View file

@ -101,6 +101,8 @@ func NewNGINXController(config *Configuration, mc metric.Collector, fs file.File
stopCh: make(chan struct{}),
updateCh: channels.NewRingChannel(1024),
ngxErrCh: make(chan error),
stopLock: &sync.Mutex{},
fileSystem: fs,