mirror of
https://git.suyu.dev/suyu/mbedtls.git
synced 2025-12-24 08:16:33 +01:00
Add separate test for xxx_free() functions in ECP module
This commit is contained in:
parent
5edcfa529f
commit
57b684f9d1
2 changed files with 19 additions and 5 deletions
|
|
@ -13,6 +13,22 @@
|
|||
* END_DEPENDENCIES
|
||||
*/
|
||||
|
||||
/* BEGIN_CASE */
|
||||
void ecp_valid_param( )
|
||||
{
|
||||
TEST_VALID_PARAM( mbedtls_ecp_point_free( NULL ) );
|
||||
TEST_VALID_PARAM( mbedtls_ecp_keypair_free( NULL ) );
|
||||
TEST_VALID_PARAM( mbedtls_ecp_point_free( NULL ) );
|
||||
|
||||
#if defined(MBEDTLS_ECP_RESTARTABLE)
|
||||
TEST_VALID_PARAM( mbedtls_ecp_restart_free( NULL ) );
|
||||
#endif /* MBEDTLS_ECP_RESTARTABLE */
|
||||
|
||||
exit:
|
||||
return;
|
||||
}
|
||||
/* END_CASE */
|
||||
|
||||
/* BEGIN_CASE depends_on:MBEDTLS_CHECK_PARAMS:!MBEDTLS_PARAM_FAILED_ALT */
|
||||
void ecp_invalid_param( )
|
||||
{
|
||||
|
|
@ -32,13 +48,8 @@ void ecp_invalid_param( )
|
|||
TEST_INVALID_PARAM( mbedtls_ecp_keypair_init( NULL ) );
|
||||
TEST_INVALID_PARAM( mbedtls_ecp_point_init( NULL ) );
|
||||
|
||||
TEST_VALID_PARAM( mbedtls_ecp_point_free( NULL ) );
|
||||
TEST_VALID_PARAM( mbedtls_ecp_keypair_free( NULL ) );
|
||||
TEST_VALID_PARAM( mbedtls_ecp_point_free( NULL ) );
|
||||
|
||||
#if defined(MBEDTLS_ECP_RESTARTABLE)
|
||||
TEST_INVALID_PARAM( mbedtls_ecp_restart_init( NULL ) );
|
||||
TEST_VALID_PARAM( mbedtls_ecp_restart_free( NULL ) );
|
||||
#endif /* MBEDTLS_ECP_RESTARTABLE */
|
||||
|
||||
TEST_INVALID_PARAM_RET( MBEDTLS_ERR_ECP_BAD_INPUT_DATA,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue