From 2717eaf1e0a71ac773c07e4a34907bcf61892810 Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Tue, 14 Apr 2020 21:28:42 +0200 Subject: [PATCH] Fix build failure with MBEDTLS_PLATFORM_NV_SEED_ALT An earlier botched backport (d56ca658ab8bd49cbbde8790240ec4074c0a7622) had the wrong name for a variable and a missing header inclusion. Signed-off-by: Gilles Peskine --- tests/suites/test_suite_entropy.function | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/suites/test_suite_entropy.function b/tests/suites/test_suite_entropy.function index 3b87244d0..cb5e20462 100644 --- a/tests/suites/test_suite_entropy.function +++ b/tests/suites/test_suite_entropy.function @@ -1,6 +1,7 @@ /* BEGIN_HEADER */ #include "mbedtls/entropy.h" #include "mbedtls/entropy_poll.h" +#include "mbedtls/md.h" /* * Number of calls made to entropy_dummy_source() @@ -346,7 +347,7 @@ void entropy_nv_seed( char *read_seed_str ) // Set the initial NV seed to read. // Get exactly MBEDTLS_ENTROPY_BLOCK_SIZE bytes from read_str. - TEST_ASSERT( strlen( read_seed ) / 2 >= MBEDTLS_ENTROPY_BLOCK_SIZE ); + TEST_ASSERT( strlen( read_seed_str ) / 2 >= MBEDTLS_ENTROPY_BLOCK_SIZE ); read_seed_str[MBEDTLS_ENTROPY_BLOCK_SIZE * 2] = '\0'; unhexify( read_seed, read_seed_str ); memcpy( buffer_seed, read_seed, MBEDTLS_ENTROPY_BLOCK_SIZE );