mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-12-23 10:55:27 +00:00
Fix error code
PSA_ERROR_BAD_STATE means that the function was called on a context in a bad state. This error is something that can't happen while only using the PSA API and therefore a PSA_ERROR_CORRUPTION_DETECTED is a more appropriate error code.
This commit is contained in:
parent
5fe19734d5
commit
30090bc2cf
|
@ -4141,7 +4141,7 @@ static psa_status_t psa_key_derivation_tls12_prf_generate_next_block(
|
|||
* object was corrupted or if this function is called directly
|
||||
* inside the library. */
|
||||
if( tls12_prf->block_number == 0xff )
|
||||
return( PSA_ERROR_BAD_STATE );
|
||||
return( PSA_ERROR_CORRUPTION_DETECTED );
|
||||
|
||||
/* We need a new block */
|
||||
++tls12_prf->block_number;
|
||||
|
|
Loading…
Reference in a new issue