diff --git a/src/share/native/sun/security/ec/ec.c b/src/share/native/sun/security/ec/ec.c index d77f110af645e42328e15660cdd225c85dc557a5..0eda7da753b9ce0388666465a118b164dc28eabd 100644 --- a/src/share/native/sun/security/ec/ec.c +++ b/src/share/native/sun/security/ec/ec.c @@ -422,7 +422,7 @@ ec_GenerateRandomPrivateKey(const unsigned char *order, int len, */ if ((privKeyBytes = PORT_Alloc(2*len, kmflag)) == NULL) goto cleanup; if (randomlen != 2 * len) { - goto cleanup; + randomlen = 2 * len; } /* No need to generate - random bytes are now supplied */ /* CHECK_SEC_OK( RNG_GenerateGlobalRandomBytes(privKeyBytes, 2*len) );*/ diff --git a/test/sun/security/ec/TestEC.java b/test/sun/security/ec/TestEC.java index 0f87692a01a31a4c9fe308172ac55abcb4b92466..12694a03c649fbd2e3ac1a1b2bec8c94cf6abc63 100644 --- a/test/sun/security/ec/TestEC.java +++ b/test/sun/security/ec/TestEC.java @@ -53,7 +53,7 @@ public class TestEC { long start = System.currentTimeMillis(); new TestECDH().main(p); new TestECDSA().main(p); - //new TestCurves().main(p); + new TestCurves().main(p); new TestKeyFactory().main(p); new TestECGenSpec().main(p); new ReadPKCS12().main(p);