diff options
Diffstat (limited to 'libgo/go/crypto/sha256/sha256.go')
-rw-r--r-- | libgo/go/crypto/sha256/sha256.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libgo/go/crypto/sha256/sha256.go b/libgo/go/crypto/sha256/sha256.go index e1cccf65a60..659531dc716 100644 --- a/libgo/go/crypto/sha256/sha256.go +++ b/libgo/go/crypto/sha256/sha256.go @@ -259,12 +259,12 @@ func Sum256(data []byte) [Size]byte { } // Sum224 returns the SHA224 checksum of the data. -func Sum224(data []byte) (sum224 [Size224]byte) { +func Sum224(data []byte) [Size224]byte { var d digest d.is224 = true d.Reset() d.Write(data) sum := d.checkSum() - copy(sum224[:], sum[:Size224]) - return + ap := (*[Size224]byte)(sum[:]) + return *ap } |