Remove redundant null check
mbedtls_cipher_info_get_xxx has well-defined behavior on NULL, so no need to check first. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
parent
e720dbe177
commit
ce9e3a92fe
1 changed files with 0 additions and 2 deletions
|
@ -138,8 +138,6 @@ int mbedtls_ssl_ticket_setup( mbedtls_ssl_ticket_context *ctx,
|
|||
ctx->ticket_lifetime = lifetime;
|
||||
|
||||
cipher_info = mbedtls_cipher_info_from_type( cipher);
|
||||
if( cipher_info == NULL )
|
||||
return( MBEDTLS_ERR_SSL_BAD_INPUT_DATA );
|
||||
|
||||
if( mbedtls_cipher_info_get_mode( cipher_info ) != MBEDTLS_MODE_GCM &&
|
||||
mbedtls_cipher_info_get_mode( cipher_info ) != MBEDTLS_MODE_CCM )
|
||||
|
|
Loading…
Reference in a new issue