diff options
Diffstat (limited to 'src/lib/libcrypto/evp/digest.c')
| -rw-r--r-- | src/lib/libcrypto/evp/digest.c | 8 | 
1 files changed, 2 insertions, 6 deletions
| diff --git a/src/lib/libcrypto/evp/digest.c b/src/lib/libcrypto/evp/digest.c index d14e8e48d5..467e6b5ae9 100644 --- a/src/lib/libcrypto/evp/digest.c +++ b/src/lib/libcrypto/evp/digest.c | |||
| @@ -267,7 +267,6 @@ int EVP_DigestFinal_ex(EVP_MD_CTX *ctx, unsigned char *md, unsigned int *size) | |||
| 267 | return FIPS_digestfinal(ctx, md, size); | 267 | return FIPS_digestfinal(ctx, md, size); | 
| 268 | #else | 268 | #else | 
| 269 | int ret; | 269 | int ret; | 
| 270 | |||
| 271 | OPENSSL_assert(ctx->digest->md_size <= EVP_MAX_MD_SIZE); | 270 | OPENSSL_assert(ctx->digest->md_size <= EVP_MAX_MD_SIZE); | 
| 272 | ret=ctx->digest->final(ctx,md); | 271 | ret=ctx->digest->final(ctx,md); | 
| 273 | if (size != NULL) | 272 | if (size != NULL) | 
| @@ -366,11 +365,8 @@ int EVP_Digest(const void *data, size_t count, | |||
| 366 | 365 | ||
| 367 | void EVP_MD_CTX_destroy(EVP_MD_CTX *ctx) | 366 | void EVP_MD_CTX_destroy(EVP_MD_CTX *ctx) | 
| 368 | { | 367 | { | 
| 369 | if (ctx) | 368 | EVP_MD_CTX_cleanup(ctx); | 
| 370 | { | 369 | OPENSSL_free(ctx); | 
| 371 | EVP_MD_CTX_cleanup(ctx); | ||
| 372 | OPENSSL_free(ctx); | ||
| 373 | } | ||
| 374 | } | 370 | } | 
| 375 | 371 | ||
| 376 | /* This call frees resources associated with the context */ | 372 | /* This call frees resources associated with the context */ | 
