提交 e80a0f65 编写于 作者: N Nicola Tuveri 提交者: Richard Levitte

Remove more stale code in ecdhtest.c

Reviewed-by: NRich Salz <rsalz@openssl.org>
Reviewed-by: NRichard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/3187)
上级 29cbf152
......@@ -212,10 +212,8 @@ static int ecdh_cavs_kat(BIO *out, const ecdh_cavs_kat_t *kat)
int main(int argc, char *argv[])
{
BN_CTX *ctx = NULL;
int ret = 1;
EC_builtin_curve *curves = NULL;
size_t crv_len = 0, n = 0;
size_t n = 0;
BIO *out;
CRYPTO_set_mem_debug(1);
......@@ -228,16 +226,6 @@ int main(int argc, char *argv[])
EXIT(1);
BIO_set_fp(out, stdout, BIO_NOCLOSE | BIO_FP_TEXT);
if ((ctx = BN_CTX_new()) == NULL)
goto err;
/* get a list of all internal curves */
crv_len = EC_get_builtin_curves(NULL, 0);
curves = OPENSSL_malloc(sizeof(*curves) * crv_len);
if (curves == NULL) goto err;
if (!EC_get_builtin_curves(curves, crv_len)) goto err;
/* NAMED CURVES TESTS: moved to evptests.txt */
/* KATs: moved to evptests.txt */
......@@ -252,8 +240,6 @@ int main(int argc, char *argv[])
err:
ERR_print_errors_fp(stderr);
OPENSSL_free(curves);
BN_CTX_free(ctx);
BIO_free(out);
#ifndef OPENSSL_NO_CRYPTO_MDEBUG
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册