mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-03-28 19:21:08 +00:00
Check psa_destroy_key() return in rsa_encrypt_wrap()
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
This commit is contained in:
parent
ac014ca5d9
commit
7dd3b20d36
@ -298,7 +298,10 @@ static int rsa_encrypt_wrap( void *ctx,
|
||||
ret = 0;
|
||||
|
||||
cleanup:
|
||||
psa_destroy_key( key_id );
|
||||
status = psa_destroy_key( key_id );
|
||||
if( ret == 0 && status != PSA_SUCCESS )
|
||||
ret = mbedtls_psa_err_translate_pk( status );
|
||||
|
||||
return( ret );
|
||||
}
|
||||
#else
|
||||
|
Loading…
x
Reference in New Issue
Block a user