Skip to content

Commit

Permalink
Fix swallowed error in lib/netspeed package.
Browse files Browse the repository at this point in the history
  • Loading branch information
rgooch committed Apr 17, 2019
1 parent a07cca0 commit 2aea792
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/netspeed/impl.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ import (
)

const (
procRouteFilename string = "/proc/net/route"
speedPathFormat = "/sys/class/net/%s/speed"
procRouteFilename = "/proc/net/route"
speedPathFormat = "/sys/class/net/%s/speed"
)

var (
Expand Down Expand Up @@ -64,7 +64,7 @@ func findInterfaceForHost(hostname string) (string, error) {
hostIP = make(net.IP, 4)
} else {
hostIPs, err := net.LookupIP(hostname)
if err != err {
if err != nil {
return "", err
}
if len(hostIPs) < 1 {
Expand Down

0 comments on commit 2aea792

Please sign in to comment.