]> Cypherpunks repositories - gostls13.git/commitdiff
crypto/rsa: fix loop variable capture in test
authorCherry Mui <cherryyz@google.com>
Tue, 15 Nov 2022 18:56:48 +0000 (13:56 -0500)
committerMatthew Dempsky <mdempsky@google.com>
Tue, 15 Nov 2022 19:22:59 +0000 (19:22 +0000)
Should fix builds.

Change-Id: I309eccec8d08931b1ef8fee9327a08a97c6bf871
Reviewed-on: https://go-review.googlesource.com/c/go/+/450738
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Bryan Mills <bcmills@google.com>
Run-TryBot: Cherry Mui <cherryyz@google.com>
Reviewed-by: Filippo Valsorda <filippo@golang.org>
src/crypto/rsa/rsa_test.go

index 0b1c8fb320b0a6e6bfb37c746e354bb38cb50cd2..9db78cec6181f4eb0e6c561990449357634efbc8 100644 (file)
@@ -148,6 +148,7 @@ func TestEverything(t *testing.T) {
                max = 2048
        }
        for size := min; size <= max; size++ {
+               size := size
                t.Run(fmt.Sprintf("%d", size), func(t *testing.T) {
                        t.Parallel()
                        priv, err := GenerateKey(rand.Reader, size)