Skip to content
This repository has been archived by the owner on May 26, 2022. It is now read-only.

fix go vet and staticcheck #33

Merged
merged 2 commits into from
Jul 2, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ssms.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func (sm *SSMuxer) SecureOutbound(ctx context.Context, insecure net.Conn, p peer
// ensure the correct peer connected to us
if sconn.RemotePeer() != p {
sconn.Close()
return nil, false, fmt.Errorf("Unexpected peer")
return nil, false, fmt.Errorf("unexpected peer")
}
} else {
sconn, err = tpt.SecureOutbound(ctx, insecure, p)
Expand Down
4 changes: 2 additions & 2 deletions ssms_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ func TestNoCommonProto(t *testing.T) {
defer a.Close()
_, _, err := at.SecureInbound(ctx, a)
if err == nil {
t.Fatal("conection should have failed")
t.Error("conection should have failed")
}
}()

Expand All @@ -72,7 +72,7 @@ func TestNoCommonProto(t *testing.T) {
defer b.Close()
_, _, err := bt.SecureOutbound(ctx, b, "peerA")
if err == nil {
t.Fatal("connection should have failed")
t.Error("connection should have failed")
}
}()
wg.Wait()
Expand Down