refactor: DNS

This commit is contained in:
世界
2024-12-02 23:17:01 +08:00
parent 8cc7734a92
commit eae2631208
84 changed files with 4121 additions and 1735 deletions

View File

@@ -0,0 +1,19 @@
//go:build badlinkname
package local
import (
_ "unsafe"
)
//go:linkname getSystemDNSConfig net.getSystemDNSConfig
func getSystemDNSConfig() *dnsConfig
//go:linkname nameList net.(*dnsConfig).nameList
func nameList(c *dnsConfig, name string) []string
//go:linkname lookupStaticHost net.lookupStaticHost
func lookupStaticHost(host string) ([]string, string)
//go:linkname splitHostZone net.splitHostZone
func splitHostZone(s string) (host, zone string)