mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-30 10:34:18 +01:00
Merge pull request #4678 from JoeSubbiani/FixedMissingContextFree-test_suite_aes
Backport 2.x: Add missing free context at the end of aes_crypt_xts_size()
This commit is contained in:
commit
c158213b2e
3
ChangeLog.d/issue4176.txt
Normal file
3
ChangeLog.d/issue4176.txt
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
Bugfix
|
||||||
|
* Fix a resource leak in a test suite with an alternative AES
|
||||||
|
implementation. Fixes #4176.
|
@ -210,6 +210,8 @@ void aes_crypt_xts_size( int size, int retval )
|
|||||||
/* Valid pointers are passed for builds with MBEDTLS_CHECK_PARAMS, as
|
/* Valid pointers are passed for builds with MBEDTLS_CHECK_PARAMS, as
|
||||||
* otherwise we wouldn't get to the size check we're interested in. */
|
* otherwise we wouldn't get to the size check we're interested in. */
|
||||||
TEST_ASSERT( mbedtls_aes_crypt_xts( &ctx, MBEDTLS_AES_ENCRYPT, length, data_unit, src, output ) == retval );
|
TEST_ASSERT( mbedtls_aes_crypt_xts( &ctx, MBEDTLS_AES_ENCRYPT, length, data_unit, src, output ) == retval );
|
||||||
|
exit:
|
||||||
|
mbedtls_aes_xts_free( &ctx );
|
||||||
}
|
}
|
||||||
/* END_CASE */
|
/* END_CASE */
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user