Skip to content

Commit

Permalink
Add more debug logs
Browse files Browse the repository at this point in the history
  • Loading branch information
kayrus committed Feb 3, 2021
1 parent 69f6ef4 commit 3277251
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions routes/routes.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ func Get(routes, excludeRoutes, addr, gw, mask string) (net.IP, []*net.IPNet, er
for _, cidr := range strings.FieldsFunc(routes, splitFunc) {
if v := net.ParseIP(cidr).To4(); v != nil {
res.InsertNet(getNet(v))
log.Debugf("including %s (%s) to routes", cidr, v)
continue
}

Expand All @@ -52,6 +53,7 @@ func Get(routes, excludeRoutes, addr, gw, mask string) (net.IP, []*net.IPNet, er
}
return nil, nil, fmt.Errorf("failed to parse %s CIDR: %v", cidr, err)
}
log.Debugf("including %s (%s) to routes", cidr, v)
res.InsertNet(v)
}

Expand Down

0 comments on commit 3277251

Please sign in to comment.