Skip to content

Commit

Permalink
Use upstream timeout field
Browse files Browse the repository at this point in the history
  • Loading branch information
lixmal committed Jan 29, 2024
1 parent e772292 commit 631fa43
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion client/internal/dns/upstream_ios.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ func newUpstreamResolver(parentCTX context.Context, interfaceName string, ip net
}

func (u *upstreamResolverIOS) exchange(upstream string, r *dns.Msg) (rm *dns.Msg, t time.Duration, err error) {
ctx, cancel := context.WithTimeout(context.Background(), time.Second*15)
ctx, cancel := context.WithTimeout(context.Background(), u.upstreamTimeout)
defer cancel()
return u.exchangeContext(ctx, upstream, r)
}
Expand Down

0 comments on commit 631fa43

Please sign in to comment.