1
0
mirror of https://github.com/golang/go synced 2024-11-23 14:50:07 -07:00

crypto/cipher: fix duplicated arguments to bytes.Equal in test

Args were duplicated by a mistake. Found using static analysis tools.

Change-Id: I2f61e09844bc409b1f687d654767332d93dd39a2
Reviewed-on: https://go-review.googlesource.com/c/go/+/164937
Reviewed-by: Emmanuel Odeke <emm.odeke@gmail.com>
This commit is contained in:
Iskander Sharipov 2019-03-02 09:51:44 +03:00 committed by Filippo Valsorda
parent 359fb4a9af
commit 8782fd0431

View File

@ -81,7 +81,7 @@ func TestCFBVectors(t *testing.T) {
plaintextCopy := make([]byte, len(ciphertext))
cfbdec.XORKeyStream(plaintextCopy, ciphertext)
if !bytes.Equal(plaintextCopy, plaintextCopy) {
if !bytes.Equal(plaintextCopy, plaintext) {
t.Errorf("#%d: wrong plaintext: got %x, expected %x", i, plaintextCopy, plaintext)
}
}