From 25c4fa8fb0537fbb9d5a4af42d1b4643e9ee9aca Mon Sep 17 00:00:00 2001 From: Janos Follath Date: Fri, 6 Jul 2018 16:23:25 +0100 Subject: [PATCH] Fix copy paste error PSA test suite At this point it fixes memory leaks as well. These memory leaks are the fault of the 'psa_cipher_finish()' function and the calls fixed in this commit (among with many others in the test suite) will become obsolete after fixing 'psa_cipher_finish()'. --- tests/suites/test_suite_psa_crypto.function | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/suites/test_suite_psa_crypto.function b/tests/suites/test_suite_psa_crypto.function index c90447f81..715236896 100644 --- a/tests/suites/test_suite_psa_crypto.function +++ b/tests/suites/test_suite_psa_crypto.function @@ -1385,7 +1385,7 @@ void cipher_verify_output( int alg_arg, int key_type_arg, output2_length += function_output_length; - TEST_ASSERT( psa_cipher_abort( &operation1 ) == PSA_SUCCESS ); + TEST_ASSERT( psa_cipher_abort( &operation2 ) == PSA_SUCCESS ); TEST_ASSERT( input->len == output2_length ); TEST_ASSERT( memcmp( input->x, output2, input->len ) == 0 ); @@ -1491,7 +1491,7 @@ void cipher_verify_output_multipart( int alg_arg, &function_output_length ) == PSA_SUCCESS ); output2_length += function_output_length; - TEST_ASSERT( psa_cipher_abort( &operation1 ) == PSA_SUCCESS ); + TEST_ASSERT( psa_cipher_abort( &operation2 ) == PSA_SUCCESS ); TEST_ASSERT( input->len == output2_length ); TEST_ASSERT( memcmp( input->x, output2, input->len ) == 0 );