netutils: minor cleanups

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn
2020-10-31 17:57:38 +01:00
parent 888e75dfc9
commit ff141d366f
2 changed files with 5 additions and 9 deletions

View File

@@ -69,10 +69,7 @@ func GenerateIfaceName(nlh *netlink.Handle, prefix string, len int) (string, err
// list the first IPv4 address which does not conflict with other
// interfaces on the system.
func ElectInterfaceAddresses(name string) ([]*net.IPNet, []*net.IPNet, error) {
var (
v4Nets []*net.IPNet
v6Nets []*net.IPNet
)
var v4Nets, v6Nets []*net.IPNet
defer osl.InitOSContext()()