Remove ecp_c undefine routines
Signed-off-by: Jerry Yu <jerry.h.yu@arm.com>
This commit is contained in:
parent
b60e3cf424
commit
7c522d4941
1 changed files with 6 additions and 12 deletions
|
@ -120,13 +120,12 @@ static int ssl_tls13_write_named_group_list_ecdhe( mbedtls_ssl_context *ssl,
|
|||
size_t *olen )
|
||||
{
|
||||
unsigned char *p = buf;
|
||||
#if !defined(MBEDTLS_ECP_C)
|
||||
((void) ssl);
|
||||
#endif
|
||||
|
||||
*olen = 0;
|
||||
|
||||
#if defined(MBEDTLS_ECP_C)
|
||||
if( ssl->conf->curve_list == NULL )
|
||||
return( MBEDTLS_ERR_SSL_BAD_CONFIG );
|
||||
|
||||
for ( const mbedtls_ecp_group_id *grp_id = ssl->conf->curve_list;
|
||||
*grp_id != MBEDTLS_ECP_DP_NONE;
|
||||
grp_id++ )
|
||||
|
@ -135,12 +134,7 @@ static int ssl_tls13_write_named_group_list_ecdhe( mbedtls_ssl_context *ssl,
|
|||
info = mbedtls_ecp_curve_info_from_grp_id( *grp_id );
|
||||
if( info == NULL )
|
||||
continue;
|
||||
#else
|
||||
for ( const mbedtls_ecp_curve_info *info = mbedtls_ecp_curve_list();
|
||||
info->grp_id != MBEDTLS_ECP_DP_NONE;
|
||||
info++ )
|
||||
{
|
||||
#endif
|
||||
|
||||
if( !mbedtls_ssl_tls13_named_group_is_ecdhe( info->tls_id ) )
|
||||
continue;
|
||||
|
||||
|
|
Loading…
Reference in a new issue