Skip to content

Commit

Permalink
Merge branch 'master' of ssh://github.com/CiscoCloud/distributive
Browse files Browse the repository at this point in the history
  • Loading branch information
langston-barrett committed Jan 4, 2016
2 parents d50956b + ad8f8b9 commit 549c283
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion netstatus/netstatus.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ func PortOpen(protocol string, port uint16) bool {
if err != nil {
log.Fatal(err)
}
return CanConnect("localhost"+fmt.Sprint(port), protocol, dur)
return CanConnect(fmt.Sprintf("localhost:%v", port), protocol, dur)
}

// ValidIP returns a boolean answering the question "is this a valid IPV4/6
Expand Down
2 changes: 1 addition & 1 deletion netstatus/netstatus_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ func TestOpenPorts(t *testing.T) {
t.Errorf(msg+": %d", port)
} else {
dur, _ := time.ParseDuration("10s")
if CanConnect("localhost:"+fmt.Sprint(port), protocol, dur) {
if CanConnect(fmt.Sprintf("localhost:%v", port), protocol, dur) {
couldConnect++
}
}
Expand Down

0 comments on commit 549c283

Please sign in to comment.