From 393bf4a8e262917af615294f749ea11c74a4762e Mon Sep 17 00:00:00 2001 From: Daniel Pouzzner Date: Sat, 27 Apr 2024 13:17:01 -0500 Subject: [PATCH] wolfssl/openssl/sha3.h: use sizeof(struct wc_Sha3) only ifdef WOLFSSL_SHA3. --- wolfssl/openssl/sha3.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/wolfssl/openssl/sha3.h b/wolfssl/openssl/sha3.h index c181202fa..9f6b0f997 100644 --- a/wolfssl/openssl/sha3.h +++ b/wolfssl/openssl/sha3.h @@ -42,7 +42,11 @@ * to Sha3 is expected to also be 16 byte aligned addresses. */ struct WOLFSSL_SHA3_CTX { /* big enough to hold wolfcrypt Sha3, but check on init */ +#ifdef WOLFSSL_SHA3 ALIGN16 void* holder[sizeof(struct wc_Sha3)]; +#else + ALIGN16 void* holder[(424 + WC_ASYNC_DEV_SIZE) / sizeof(void*)]; +#endif }; #ifndef WOLFSSL_NOSHA3_224