Skip to content

Commit

Permalink
Fix linter warning
Browse files Browse the repository at this point in the history
sshauditor/netutil.go:21::warning: declaration of "ip" shadows
declaration at netutil.go:17 (vetshadow)
  • Loading branch information
JustinAzoff committed Nov 19, 2017
1 parent f9e0f8f commit 391deb0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sshauditor/netutil.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ func ExpandCIDRs(netblocks []string) ([]string, error) {
if err != nil {
return hosts, err
}
for ip := ip.Mask(ipnet.Mask); ipnet.Contains(ip); inc(ip) {
hosts = append(hosts, ip.String())
for h := ip.Mask(ipnet.Mask); ipnet.Contains(h); inc(h) {
hosts = append(hosts, h.String())
}
}
return hosts, nil
Expand Down

0 comments on commit 391deb0

Please sign in to comment.