mirror of
https://github.com/SagerNet/sing-box.git
synced 2025-06-11 21:04:13 +08:00
Fix default dns transport strategy
This commit is contained in:
parent
871f4aebbd
commit
0c48aaef08
@ -37,7 +37,11 @@ func (r *Router) matchDNS(ctx context.Context) (context.Context, dns.Transport,
|
|||||||
r.dnsLogger.ErrorContext(ctx, "transport not found: ", detour)
|
r.dnsLogger.ErrorContext(ctx, "transport not found: ", detour)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return ctx, r.defaultTransport, r.defaultDomainStrategy
|
if domainStrategy, dsLoaded := r.transportDomainStrategy[r.defaultTransport]; dsLoaded {
|
||||||
|
return ctx, r.defaultTransport, domainStrategy
|
||||||
|
} else {
|
||||||
|
return ctx, r.defaultTransport, r.defaultDomainStrategy
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *Router) Exchange(ctx context.Context, message *dnsmessage.Message) (*dnsmessage.Message, error) {
|
func (r *Router) Exchange(ctx context.Context, message *dnsmessage.Message) (*dnsmessage.Message, error) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user