Minor fixes

- Not logging program name twice for wait errors
- Wait for tinyproxy to exit
This commit is contained in:
Quentin McGaw
2020-07-08 23:29:22 +00:00
parent 7d36993450
commit a39d885e34
3 changed files with 3 additions and 4 deletions

View File

@@ -2,7 +2,6 @@ package dns
import (
"context"
"fmt"
"net"
"time"
@@ -112,7 +111,7 @@ func (l *looper) Run(ctx context.Context, restart <-chan struct{}, done chan<- s
go func() {
err := waitFn() // blocking
if unboundCtx.Err() != context.Canceled {
waitError <- fmt.Errorf("unbound: %w", err)
waitError <- err
}
}()

View File

@@ -2,7 +2,6 @@ package openvpn
import (
"context"
"fmt"
"time"
"github.com/qdm12/golibs/command"
@@ -62,7 +61,7 @@ func (l *looper) Run(ctx context.Context, restart <-chan struct{}, done chan<- s
go func() {
err := waitFn() // blocking
if openvpnCtx.Err() != context.Canceled {
waitError <- fmt.Errorf("openvpn: %w", err)
waitError <- err
}
}()
select {