diff --git a/src/crypto/crypto.go b/src/crypto/crypto.go index dcedb2c7..290b5365 100644 --- a/src/crypto/crypto.go +++ b/src/crypto/crypto.go @@ -236,7 +236,7 @@ func BoxOpen(shared *BoxSharedKey, n := (*[BoxNonceLen]byte)(nonce) temp := append(pool.Get().([]byte), boxed...) unboxed, success := box.OpenAfterPrecomputation(boxed[:0], temp, n, s) - pool.Put(temp[:0]) + pool.Put(temp[:0]) // nolint:staticcheck return unboxed, success } @@ -253,7 +253,7 @@ func BoxSeal(shared *BoxSharedKey, unboxed []byte, nonce *BoxNonce) ([]byte, *Bo n := (*[BoxNonceLen]byte)(nonce) temp := append(pool.Get().([]byte), unboxed...) boxed := box.SealAfterPrecomputation(unboxed[:0], temp, n, s) - pool.Put(temp[:0]) + pool.Put(temp[:0]) // nolint:staticcheck return boxed, nonce } diff --git a/src/tuntap/tun_darwin.go b/src/tuntap/tun_darwin.go index e80638f4..6804fd65 100644 --- a/src/tuntap/tun_darwin.go +++ b/src/tuntap/tun_darwin.go @@ -41,8 +41,8 @@ const ( ) type in6_addrlifetime struct { - ia6t_expire float64 // nolint:unused nolint:structcheck - ia6t_preferred float64 // nolint:unused nolint:structcheck + ia6t_expire float64 // nolint:unused,structcheck + ia6t_preferred float64 // nolint:unused,structcheck ia6t_vltime uint32 ia6t_pltime uint32 } @@ -50,16 +50,16 @@ type in6_addrlifetime struct { type sockaddr_in6 struct { sin6_len uint8 sin6_family uint8 - sin6_port uint8 // nolint:unused nolint:structcheck - sin6_flowinfo uint32 // nolint:unused nolint:structcheck + sin6_port uint8 // nolint:unused,structcheck + sin6_flowinfo uint32 // nolint:unused,structcheck sin6_addr [8]uint16 - sin6_scope_id uint32 // nolint:unused nolint:structcheck + sin6_scope_id uint32 // nolint:unused,structcheck } type in6_aliasreq struct { ifra_name [16]byte ifra_addr sockaddr_in6 - ifra_dstaddr sockaddr_in6 // nolint:unused nolint:structcheck + ifra_dstaddr sockaddr_in6 // nolint:unused,structcheck ifra_prefixmask sockaddr_in6 ifra_flags uint32 ifra_lifetime in6_addrlifetime diff --git a/src/yggdrasil/pool.go b/src/yggdrasil/pool.go index e95236a5..e639aeb9 100644 --- a/src/yggdrasil/pool.go +++ b/src/yggdrasil/pool.go @@ -16,5 +16,5 @@ func pool_getBytes(size int) []byte { } func pool_putBytes(bs []byte) { - pool.Put(bs) + pool.Put(bs) // nolint:staticcheck }