Skip to content

Commit

Permalink
refactor: resolve remaining linter warnings
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Stewart <christian@aperture.us>
  • Loading branch information
paralin committed Jul 1, 2024
1 parent 0aef2ed commit 82dc570
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 2 additions & 3 deletions internal/handshake/cipher_suite.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,8 @@ type xorNonceAEAD struct {
aead cipher.AEAD
}

func (f *xorNonceAEAD) NonceSize() int { return 8 } // 64-bit sequence number
func (f *xorNonceAEAD) Overhead() int { return f.aead.Overhead() }
func (f *xorNonceAEAD) explicitNonceLen() int { return 0 }
func (f *xorNonceAEAD) NonceSize() int { return 8 } // 64-bit sequence number
func (f *xorNonceAEAD) Overhead() int { return f.aead.Overhead() }

func (f *xorNonceAEAD) Seal(out, nonce, plaintext, additionalData []byte) []byte {
for i, b := range nonce {
Expand Down
2 changes: 2 additions & 0 deletions sys_conn.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ var _ OOBCapablePacketConn = &net.UDPConn{}

func wrapConn(pc net.PacketConn) (rawConn, error) {
if err := setReceiveBuffer(pc); err != nil {
_ = err
/*
if !strings.Contains(err.Error(), "use of closed network connection") {
setBufferWarningOnce.Do(func() {
Expand All @@ -36,6 +37,7 @@ func wrapConn(pc net.PacketConn) (rawConn, error) {
*/
}
if err := setSendBuffer(pc); err != nil {
_ = err
/*
if !strings.Contains(err.Error(), "use of closed network connection") {
setBufferWarningOnce.Do(func() {
Expand Down

0 comments on commit 82dc570

Please sign in to comment.