diff --git a/src/internal.c b/src/internal.c index 947ac2491..8f479c2b0 100644 --- a/src/internal.c +++ b/src/internal.c @@ -11180,8 +11180,10 @@ static WC_INLINE int GrowOutputBuffer(WOLFSSL* ssl, int size) return BUFFER_E; if (! WC_SAFE_SUM_WORD32(newSz, (word32)size, newSz)) return BUFFER_E; +#if WOLFSSL_GENERAL_ALIGNMENT > 0 if (! WC_SAFE_SUM_WORD32(newSz, align, newSz)) return BUFFER_E; +#endif tmp = (byte*)XMALLOC(newSz, ssl->heap, DYNAMIC_TYPE_OUT_BUFFER); newSz -= align; WOLFSSL_MSG("growing output buffer"); diff --git a/wolfcrypt/src/memory.c b/wolfcrypt/src/memory.c index ae57c5f67..c0b7ef0a0 100644 --- a/wolfcrypt/src/memory.c +++ b/wolfcrypt/src/memory.c @@ -551,7 +551,7 @@ void wolfSSL_SetDebugMemoryCb(DebugMemoryCb cb) wc_Memory** list is the list that new buckets are prepended to */ static int wc_create_memory_buckets(byte* buffer, word32 bufSz, - word32 buckSz, byte buckNum, wc_Memory** list) { + word32 buckSz, word32 buckNum, wc_Memory** list) { byte* pt = buffer; int ret = 0; byte memSz = (byte)sizeof(wc_Memory);