cmd/cli: ignore un-usable interfaces on darwin

So multi interfaces config won't emit un-necessary errors if the network
cable adapters are not being used on MacOS.
This commit is contained in:
Cuong Manh Le
2024-03-06 15:05:08 +07:00
committed by Cuong Manh Le
parent a9672dfff5
commit 8c7c3901e8
5 changed files with 30 additions and 2 deletions
+1 -1
View File
@@ -477,7 +477,7 @@ func (p *prog) setDNS() {
}
if allIfaces {
withEachPhysicalInterfaces(netIface.Name, "set DNS", func(i *net.Interface) error {
return setDNS(i, nameservers)
return setDnsIgnoreUnusableInterface(i, nameservers)
})
}
}