test: pake: fix error in ssl_ecjpake_set_password()

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
This commit is contained in:
Valerio Setti 2022-12-06 11:41:57 +01:00
parent 70e029006d
commit 2e1e43fb82

View file

@ -6206,7 +6206,7 @@ void ssl_ecjpake_set_password( int use_opaque_arg )
#else /* MBEDTLS_USE_PSA_CRYPTO */
(void) use_opaque_arg;
#endif /* MBEDTLS_USE_PSA_CRYPTO */
const unsigned char pwd_string[ sizeof(ECJPAKE_TEST_PWD) ] = "";
unsigned char pwd_string[ sizeof(ECJPAKE_TEST_PWD) ] = "";
size_t pwd_len = 0;
int ret;
@ -6231,7 +6231,7 @@ void ssl_ecjpake_set_password( int use_opaque_arg )
ECJPAKE_TEST_SET_PASSWORD( MBEDTLS_ERR_SSL_BAD_INPUT_DATA );
pwd_len = strlen( ECJPAKE_TEST_PWD );
memcpy( (void*) pwd_string, ECJPAKE_TEST_PWD, pwd_len );
memcpy( pwd_string, ECJPAKE_TEST_PWD, pwd_len );
#if defined( MBEDTLS_USE_PSA_CRYPTO )
if( use_opaque_arg )