diff options
Diffstat (limited to 'src/regress/lib')
-rw-r--r-- | src/regress/lib/libcrypto/ec/ectest.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/regress/lib/libcrypto/ec/ectest.c b/src/regress/lib/libcrypto/ec/ectest.c index c4ef840ff2..2b9c6a99f3 100644 --- a/src/regress/lib/libcrypto/ec/ectest.c +++ b/src/regress/lib/libcrypto/ec/ectest.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ectest.c,v 1.12 2021/04/20 17:35:21 tb Exp $ */ | 1 | /* $OpenBSD: ectest.c,v 1.13 2023/04/13 05:25:30 tb Exp $ */ |
2 | /* crypto/ec/ectest.c */ | 2 | /* crypto/ec/ectest.c */ |
3 | /* | 3 | /* |
4 | * Originally written by Bodo Moeller for the OpenSSL project. | 4 | * Originally written by Bodo Moeller for the OpenSSL project. |
@@ -103,11 +103,17 @@ group_order_tests(EC_GROUP *group) | |||
103 | BIGNUM *n1, *n2, *order; | 103 | BIGNUM *n1, *n2, *order; |
104 | EC_POINT *P = EC_POINT_new(group); | 104 | EC_POINT *P = EC_POINT_new(group); |
105 | EC_POINT *Q = EC_POINT_new(group); | 105 | EC_POINT *Q = EC_POINT_new(group); |
106 | BN_CTX *ctx = BN_CTX_new(); | 106 | BN_CTX *ctx; |
107 | 107 | ||
108 | n1 = BN_new(); | 108 | if ((ctx = BN_CTX_new()) == NULL) |
109 | n2 = BN_new(); | 109 | ABORT; |
110 | order = BN_new(); | 110 | |
111 | if ((n1 = BN_new()) == NULL) | ||
112 | ABORT; | ||
113 | if ((n2 = BN_new()) == NULL) | ||
114 | ABORT; | ||
115 | if ((order = BN_new()) == NULL) | ||
116 | ABORT; | ||
111 | fprintf(stdout, "verify group order ..."); | 117 | fprintf(stdout, "verify group order ..."); |
112 | fflush(stdout); | 118 | fflush(stdout); |
113 | if (!EC_GROUP_get_order(group, order, ctx)) | 119 | if (!EC_GROUP_get_order(group, order, ctx)) |