net/interfaces: explicitly check netaddr.IP.Is6 in isUsableV6

Signed-off-by: Matt Layher <mdlayher@gmail.com>
This commit is contained in:
Matt Layher
2021-07-28 14:30:06 -04:00
committed by Denton Gentry
parent 3ff8a55fa7
commit effee49e45
2 changed files with 3 additions and 1 deletions

View File

@@ -58,6 +58,8 @@ func TestIsUsableV6(t *testing.T) {
{"zeros", "0000:0000:0000:0000:0000:0000:0000:0000", false},
{"Link Local", "fe80::1", false},
{"Global", "2602::1", true},
{"IPv4 public", "192.0.2.1", false},
{"IPv4 private", "192.168.1.1", false},
}
for _, test := range tests {