aboutsummaryrefslogtreecommitdiffstats
path: root/src/libstrongswan/plugins/openssl/openssl_util.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstrongswan/plugins/openssl/openssl_util.c')
-rw-r--r--src/libstrongswan/plugins/openssl/openssl_util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstrongswan/plugins/openssl/openssl_util.c b/src/libstrongswan/plugins/openssl/openssl_util.c
index 2f9813701..914060358 100644
--- a/src/libstrongswan/plugins/openssl/openssl_util.c
+++ b/src/libstrongswan/plugins/openssl/openssl_util.c
@@ -51,7 +51,7 @@ bool openssl_hash_chunk(int hash_type, chunk_t data, chunk_t *hash)
goto error;
}
- *hash = chunk_alloc(hasher->md_size);
+ *hash = chunk_alloc(EVP_MD_size(hasher));
if (!EVP_DigestFinal_ex(ctx, hash->ptr, NULL))
{
chunk_free(hash);