mirror of
https://github.com/minio/minio.git
synced 2025-11-07 04:42:56 -05:00
Golint fixes
This commit is contained in:
@@ -21,17 +21,17 @@ package cpu
|
||||
// int has_avx2 (void);
|
||||
import "C"
|
||||
|
||||
// CPUID instruction verification wrapper for SSE41 extensions
|
||||
// HasSSE41 - CPUID instruction verification wrapper for SSE41 extensions
|
||||
func HasSSE41() bool {
|
||||
return int(C.has_sse41()) == 1
|
||||
}
|
||||
|
||||
// CPUID instruction verification wrapper for AVX extensions
|
||||
// HasAVX - CPUID instruction verification wrapper for AVX extensions
|
||||
func HasAVX() bool {
|
||||
return int(C.has_avx()) == 1
|
||||
}
|
||||
|
||||
// CPUID instruction verification wrapper for AVX2 extensions
|
||||
// HasAVX2 - CPUID instruction verification wrapper for AVX2 extensions
|
||||
func HasAVX2() bool {
|
||||
return int(C.has_avx2()) == 1
|
||||
}
|
||||
|
||||
@@ -98,10 +98,10 @@ func (d *digest) Write(p []byte) (nn int, err error) {
|
||||
}
|
||||
|
||||
// Return checksum bytes
|
||||
func (d0 *digest) Sum(in []byte) []byte {
|
||||
func (d *digest) Sum(in []byte) []byte {
|
||||
// Make a copy of d0 so that caller can keep writing and summing.
|
||||
d := *d0
|
||||
hash := d.checkSum()
|
||||
d0 := *d
|
||||
hash := d0.checkSum()
|
||||
return append(in, hash[:]...)
|
||||
}
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ import (
|
||||
"crypto/sha512"
|
||||
)
|
||||
|
||||
// The size of a SHA512 checksum in bytes.
|
||||
const (
|
||||
Size = sha512.Size
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user