Skip to content

Commit

Permalink
fix minor unreachable code caused by t.Fatal
Browse files Browse the repository at this point in the history
Signed-off-by: Abirdcfly <[email protected]>
  • Loading branch information
Abirdcfly authored and rfjakob committed Aug 15, 2022
1 parent e9ecff7 commit 702a2e1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/stupidgcm/common_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,11 @@ func testEncryptDecrypt(t *testing.T, c1 cipher.AEAD, c2 cipher.AEAD) {

// Ciphertext must be identical to Go GCM
if !bytes.Equal(c1out, c2out) {
t.Fatalf("Compare failed for encryption, size %d", i)
t.Log("c1out:")
t.Log("\n" + hex.Dump(c1out))
t.Log("c2out:")
t.Log("\n" + hex.Dump(c2out))
t.Fatalf("Compare failed for encryption, size %d", i)
}

c1out2, sErr := c1.Open(dst, iv, c1out[len(dst):], authData)
Expand Down Expand Up @@ -115,11 +115,11 @@ func testInplaceSeal(t *testing.T, c1 cipher.AEAD, c2 cipher.AEAD) {

// Ciphertext must be identical to Go GCM
if !bytes.Equal(c1out, c2out) {
t.Fatalf("Compare failed for encryption, size %d", i)
t.Log("sOut:")
t.Log("\n" + hex.Dump(c1out))
t.Log("gOut:")
t.Log("\n" + hex.Dump(c2out))
t.Fatalf("Compare failed for encryption, size %d", i)
}
}
}
Expand Down

0 comments on commit 702a2e1

Please sign in to comment.