diff options
Diffstat (limited to 'src/lib/libcrypto/ec/ecp_nist.c')
| -rw-r--r-- | src/lib/libcrypto/ec/ecp_nist.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/lib/libcrypto/ec/ecp_nist.c b/src/lib/libcrypto/ec/ecp_nist.c index d49d1735f3..a33f9d9e39 100644 --- a/src/lib/libcrypto/ec/ecp_nist.c +++ b/src/lib/libcrypto/ec/ecp_nist.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: ecp_nist.c,v 1.8 2014/06/12 15:49:29 deraadt Exp $ */ | 1 | /* $OpenBSD: ecp_nist.c,v 1.9 2014/07/12 16:03:37 miod Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Written by Nils Larsch for the OpenSSL project. | 3 | * Written by Nils Larsch for the OpenSSL project. |
| 4 | */ | 4 | */ |
| @@ -153,8 +153,7 @@ ec_GFp_nist_group_set_curve(EC_GROUP *group, const BIGNUM *p, | |||
| 153 | 153 | ||
| 154 | err: | 154 | err: |
| 155 | BN_CTX_end(ctx); | 155 | BN_CTX_end(ctx); |
| 156 | if (new_ctx != NULL) | 156 | BN_CTX_free(new_ctx); |
| 157 | BN_CTX_free(new_ctx); | ||
| 158 | return ret; | 157 | return ret; |
| 159 | } | 158 | } |
| 160 | 159 | ||
| @@ -181,8 +180,7 @@ ec_GFp_nist_field_mul(const EC_GROUP *group, BIGNUM *r, const BIGNUM *a, | |||
| 181 | 180 | ||
| 182 | ret = 1; | 181 | ret = 1; |
| 183 | err: | 182 | err: |
| 184 | if (ctx_new) | 183 | BN_CTX_free(ctx_new); |
| 185 | BN_CTX_free(ctx_new); | ||
| 186 | return ret; | 184 | return ret; |
| 187 | } | 185 | } |
| 188 | 186 | ||
| @@ -209,7 +207,6 @@ ec_GFp_nist_field_sqr(const EC_GROUP * group, BIGNUM * r, const BIGNUM * a, | |||
| 209 | 207 | ||
| 210 | ret = 1; | 208 | ret = 1; |
| 211 | err: | 209 | err: |
| 212 | if (ctx_new) | 210 | BN_CTX_free(ctx_new); |
| 213 | BN_CTX_free(ctx_new); | ||
| 214 | return ret; | 211 | return ret; |
| 215 | } | 212 | } |
