Skip to content
Snippets Groups Projects
Commit 3a434898 authored by ale's avatar ale
Browse files

Ignore link-local unicast addrs for DNS binds

parent 9cc96046
Branches
No related tags found
No related merge requests found
......@@ -63,7 +63,7 @@ func nonLocalAddrs() []net.IP {
addrs, _ := intf.Addrs()
for _, addr := range addrs {
ip, _, err := net.ParseCIDR(addr.String())
if err != nil || ip.IsLoopback() {
if err != nil || ip.IsLoopback() || ip.IsLinkLocalUnicast() {
continue
}
ips = append(ips, ip)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment