From fb54360f8cf551117be19a5868d3482df083af23 Mon Sep 17 00:00:00 2001 From: k-stachowiak Date: Wed, 19 Dec 2018 18:34:21 +0100 Subject: [PATCH] Prevent unused variable in some configurations --- tests/suites/test_suite_cipher.function | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/suites/test_suite_cipher.function b/tests/suites/test_suite_cipher.function index 4e616d3ef..773c792ca 100644 --- a/tests/suites/test_suite_cipher.function +++ b/tests/suites/test_suite_cipher.function @@ -35,6 +35,8 @@ void cipher_invalid_param_unconditional( ) *( mbedtls_cipher_list() ) ); size_t size_t_var; + (void)valid_mode; /* In some configurations this is unused */ + mbedtls_cipher_init( &valid_ctx ); mbedtls_cipher_setup( &valid_ctx, valid_info ); mbedtls_cipher_init( &invalid_ctx ); @@ -157,6 +159,8 @@ void cipher_invalid_param_conditional( ) size_t size_t_var; + (void)valid_mode; /* In some configurations this is unused */ + /* mbedtls_cipher_init() */ TEST_VALID_PARAM( mbedtls_cipher_init( &valid_ctx ) ); TEST_INVALID_PARAM( mbedtls_cipher_init( NULL ) );