From 5fb07c6a968e6302f05208c161b1246c223ee651 Mon Sep 17 00:00:00 2001 From: Neil Armstrong Date: Fri, 10 Jun 2022 09:00:00 +0200 Subject: [PATCH] No need to check for state in psa_pake_setup() Signed-off-by: Neil Armstrong --- library/psa_crypto_pake.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/psa_crypto_pake.c b/library/psa_crypto_pake.c index 1aa8a72d89..e7037ce2dc 100644 --- a/library/psa_crypto_pake.c +++ b/library/psa_crypto_pake.c @@ -118,7 +118,7 @@ psa_status_t psa_pake_setup( psa_pake_operation_t *operation, const psa_pake_cipher_suite_t *cipher_suite) { /* A context must be freshly initialized before it can be set up. */ - if( operation->alg != 0 || operation->state != PSA_PAKE_STATE_INVALID ) + if( operation->alg != 0 ) return( PSA_ERROR_BAD_STATE ); if( cipher_suite == NULL ||