commit | e4997651d72cc759662237b42dca3cae4aa67fa9 | [log] [tgz] |
---|---|---|
author | Paul Elliott <paul.elliott@arm.com> | Thu Oct 24 14:41:01 2024 +0100 |
committer | Paul Elliott <paul.elliott@arm.com> | Thu Oct 24 15:26:11 2024 +0100 |
tree | d4b97cb5586e66e5e19c50b8c24dd5b0306d9f42 | |
parent | 0f65366c052fbd6aa062e414ab35f8b3a922d569 [diff] |
Fix double free in case of test failure Signed-off-by: Paul Elliott <paul.elliott@arm.com>
diff --git a/tests/suites/test_suite_psa_crypto_memory.function b/tests/suites/test_suite_psa_crypto_memory.function index cc87848..50539e8 100644 --- a/tests/suites/test_suite_psa_crypto_memory.function +++ b/tests/suites/test_suite_psa_crypto_memory.function
@@ -107,7 +107,10 @@ exit: mbedtls_free(local_input.buffer); - mbedtls_free(input); + + if (local_input.buffer != input) { + mbedtls_free(input); + } } /* END_CASE */