control/controlhttp: reduce some log spam on context cancel

Change-Id: I3ac00ddb29c16e9791ab2be19f454dabd721e4c3
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
Brad Fitzpatrick 2025-03-30 21:12:29 -07:00 committed by Brad Fitzpatrick
parent 4c9b37fa2e
commit 29c2bb1db6

View File

@ -249,6 +249,11 @@ func (a *Dialer) dial(ctx context.Context) (*ClientConn, error) {
results[i].conn = nil // so we don't close it in the defer
return conn, nil
}
if ctx.Err() != nil {
a.logf("controlhttp: context aborted dialing")
return nil, ctx.Err()
}
merr := multierr.New(errs...)
// If we get here, then we didn't get anywhere with our dial plan; fall back to just using DNS.