Skip to content

Commit

Permalink
Fix for issue with wc_HashAlg being a union.
Browse files Browse the repository at this point in the history
  • Loading branch information
dgarske committed Sep 25, 2024
1 parent 32ed473 commit 6c118e1
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion wolfssl/wolfcrypt/hash.h
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,10 @@ enum wc_HashFlags {
};

#ifndef NO_HASH_WRAPPER
typedef union {
typedef struct {
#if HAVE_ANONYMOUS_INLINE_AGGREGATES
union {
#endif
#ifndef NO_MD5
wc_Md5 md5;
#endif
Expand All @@ -119,6 +122,9 @@ typedef union {
#ifdef WOLFSSL_SM3
wc_Sm3 sm3;
#endif
#if HAVE_ANONYMOUS_INLINE_AGGREGATES
};
#endif
unsigned int isAllocated:1; /* flag indicates if structure was allocated */
} wc_HashAlg;
#endif /* !NO_HASH_WRAPPER */
Expand Down

0 comments on commit 6c118e1

Please sign in to comment.