mirror of https://github.com/ARMmbed/mbed-os.git
Change the terminate limit check
Check for counter to be `< 1` instead of `<= 0` before terminating.pull/7099/head
parent
1f5cee967d
commit
666ebe392a
|
|
@ -42,7 +42,7 @@ void mbedtls_platform_teardown( mbedtls_platform_context *obsolete_ctx )
|
|||
{
|
||||
|
||||
core_util_atomic_decr_u32( ( volatile uint32_t * )&ctx.reference_count, 1 );
|
||||
if( ctx.reference_count <= 0 )
|
||||
if( ctx.reference_count < 1 )
|
||||
{
|
||||
/* call platform specific code to terminate crypto driver */
|
||||
crypto_platform_terminate( &ctx.platform_impl_ctx );
|
||||
|
|
|
|||
Loading…
Reference in New Issue