Maintenance: shutdown order
- Order of threads to shutdown (control then tickers then health etc.) - Rely on closing channels instead of waitgroups - Move exit logs from each package to the shutdown package
This commit is contained in:
@@ -3,14 +3,13 @@ package dns
|
||||
import (
|
||||
"regexp"
|
||||
"strings"
|
||||
"sync"
|
||||
|
||||
"github.com/qdm12/gluetun/internal/constants"
|
||||
"github.com/qdm12/golibs/logging"
|
||||
)
|
||||
|
||||
func (l *looper) collectLines(wg *sync.WaitGroup, stdout, stderr <-chan string) {
|
||||
defer wg.Done()
|
||||
func (l *looper) collectLines(stdout, stderr <-chan string, done chan<- struct{}) {
|
||||
defer close(done)
|
||||
var line string
|
||||
var ok bool
|
||||
for {
|
||||
|
||||
Reference in New Issue
Block a user