1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-06-25 12:41:56 +03:00

Remove unneeded NULL pointer checks in LMS tests

Signed-off-by: Raef Coles <raef.coles@arm.com>
This commit is contained in:
Raef Coles
2022-10-13 14:18:16 +01:00
parent 29c490db97
commit 1d88ea870f
2 changed files with 3 additions and 6 deletions

View File

@ -136,7 +136,6 @@ void lmots_verify_test ( data_t *msg, data_t *sig, data_t *pub_key,
} }
exit: exit:
if( tmp_sig != NULL )
mbedtls_free( tmp_sig ); mbedtls_free( tmp_sig );
mbedtls_lmots_public_free( &ctx ); mbedtls_lmots_public_free( &ctx );
} }

View File

@ -138,7 +138,6 @@ void lms_verify_test ( data_t * msg, data_t * sig, data_t * pub_key,
} }
exit: exit:
if( tmp_sig != NULL )
mbedtls_free( tmp_sig ); mbedtls_free( tmp_sig );
mbedtls_lms_public_free( &ctx ); mbedtls_lms_public_free( &ctx );
} }
@ -192,7 +191,6 @@ void lms_import_export_test ( data_t * pub_key, int expected_import_rc )
} }
exit: exit:
if( exported_pub_key != NULL )
mbedtls_free( exported_pub_key ); mbedtls_free( exported_pub_key );
mbedtls_lms_public_free( &ctx ); mbedtls_lms_public_free( &ctx );
} }