From 7c49449a79d4b60251e04264c4dc93949580ec01 Mon Sep 17 00:00:00 2001 From: Daniel Pouzzner Date: Wed, 6 Jul 2022 17:35:15 -0500 Subject: [PATCH] wolfcrypt/src/port/arm/armv8-sha512.c: gate out Sha512_Family_GetHash() in builds that have 224 and 256 bit hashes gated out, to fix unused function warning. --- wolfcrypt/src/port/arm/armv8-sha512.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/wolfcrypt/src/port/arm/armv8-sha512.c b/wolfcrypt/src/port/arm/armv8-sha512.c index 358cf06ab..7584b2498 100644 --- a/wolfcrypt/src/port/arm/armv8-sha512.c +++ b/wolfcrypt/src/port/arm/armv8-sha512.c @@ -797,6 +797,8 @@ void wc_Sha384Free(wc_Sha384* sha384) #ifdef WOLFSSL_SHA512 +#if !defined(WOLFSSL_NOSHA512_224) || !defined(WOLFSSL_NOSHA512_256) + static int Sha512_Family_GetHash(wc_Sha512* sha512, byte* hash, enum wc_HashType type ) { @@ -833,6 +835,8 @@ static int Sha512_Family_GetHash(wc_Sha512* sha512, byte* hash, return ret; } +#endif /* !WOLFSSL_NOSHA512_224 || !WOLFSSL_NOSHA512_256 */ + int wc_Sha512GetHash(wc_Sha512* sha512, byte* hash) { int ret;