Introduce psa_key_handle_is_null inline function
Signed-off-by: Ronald Cron <ronald.cron@arm.com>
This commit is contained in:
parent
91e9515424
commit
c26f8d467a
14 changed files with 46 additions and 33 deletions
|
@ -1064,10 +1064,10 @@ static inline int mbedtls_ssl_get_psk( const mbedtls_ssl_context *ssl,
|
|||
static inline psa_key_handle_t mbedtls_ssl_get_opaque_psk(
|
||||
const mbedtls_ssl_context *ssl )
|
||||
{
|
||||
if( ssl->handshake->psk_opaque != 0 )
|
||||
if( ! psa_key_handle_is_null( ssl->handshake->psk_opaque ) )
|
||||
return( ssl->handshake->psk_opaque );
|
||||
|
||||
if( ssl->conf->psk_opaque != 0 )
|
||||
if( ! psa_key_handle_is_null( ssl->conf->psk_opaque ) )
|
||||
return( ssl->conf->psk_opaque );
|
||||
|
||||
return( PSA_KEY_HANDLE_INIT );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue