chore: Make slash optional for system resolver

This commit is contained in:
H1JK 2023-05-01 12:58:02 +08:00
parent 969c235490
commit 1eefa71e1f
2 changed files with 5 additions and 1 deletions

View File

@ -974,6 +974,10 @@ func parsePureDNSServer(server string) string {
return "udp://" + server
}
if server == "system" {
return "system://"
}
if ip, err := netip.ParseAddr(server); err != nil {
if strings.Contains(server, "://") {
return server

View File

@ -177,7 +177,7 @@ dns:
- 8.8.8.8
- tls://1.12.12.12:853
- tls://223.5.5.5:853
- system:// # append DNS server from system configuration. If not found, it would print an error log and skip.
- system # append DNS server from system configuration. If not found, it would print an error log and skip.
enhanced-mode: fake-ip # or redir-host
fake-ip-range: 198.18.0.1/16 # fake-ip 池设置