diff --git a/config/config.go b/config/config.go index 6425934e5..ff16ac11a 100644 --- a/config/config.go +++ b/config/config.go @@ -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 diff --git a/docs/config.yaml b/docs/config.yaml index 66cab25cb..8721340f5 100644 --- a/docs/config.yaml +++ b/docs/config.yaml @@ -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 池设置