File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -14060,11 +14060,16 @@ static WARN_UNUSED_RESULT int AesSivCipher(
1406014060 }
1406114061 }
1406214062
14063- aes -> isAllocated = 0 ;
14064- wc_AesFree (aes );
1406514063#ifdef WOLFSSL_SMALL_STACK
14066- XFREE (aes , NULL , DYNAMIC_TYPE_AES );
14064+ if (aes != NULL )
1406714065#endif
14066+ {
14067+ aes -> isAllocated = 0 ;
14068+ wc_AesFree (aes );
14069+ #ifdef WOLFSSL_SMALL_STACK
14070+ XFREE (aes , NULL , DYNAMIC_TYPE_AES );
14071+ #endif
14072+ }
1406814073
1406914074 return ret ;
1407014075}
Original file line number Diff line number Diff line change @@ -15913,8 +15913,8 @@ static wc_test_ret_t aesccm_128_test(void)
1591315913 XMEMSET(p2, 0, sizeof(p2));
1591415914 XMEMSET(iv2, 0, sizeof(iv2));
1591515915
15916- #if defined(WOLFSSL_SMALL_STACK) && !defined(WOLFSSL_NO_MALLOC)
1591715916 wc_AesFree(enc);
15917+ #if defined(WOLFSSL_SMALL_STACK) && !defined(WOLFSSL_NO_MALLOC)
1591815918 enc = wc_AesNew(HEAP_HINT, devId);
1591915919 if (enc == NULL)
1592015920 ERROR_OUT(WC_TEST_RET_ENC_EC(MEMORY_E), out);
You can’t perform that action at this time.
0 commit comments