mirror of
https://github.com/coredns/coredns.git
synced 2025-11-01 02:33:14 -04:00
Fix ineffassign (#1959)
* Fix ineffassign This fix tries to fix ineffassign, as was reported in: https://goreportcard.com/report/github.com/coredns/coredns#ineffassign Signed-off-by: Yong Tang <yong.tang.github@outlook.com> * Update setup.go Revert this one change, so this can be merged.
This commit is contained in:
@@ -125,7 +125,8 @@ func SplitHostPort(s string) (host, port string, ipnet *net.IPNet, err error) {
|
||||
// Get the first lower octet boundary to see what encompassing zone we should be authoritative for.
|
||||
mod := (bits - ones) % sizeDigit
|
||||
nearest := (bits - ones) + mod
|
||||
offset, end := 0, false
|
||||
offset := 0
|
||||
var end bool
|
||||
for i := 0; i < nearest/sizeDigit; i++ {
|
||||
offset, end = dns.NextLabel(rev, offset)
|
||||
if end {
|
||||
|
||||
Reference in New Issue
Block a user