From cd9f86d921d387fa20d0fc336f24372def7980d5 Mon Sep 17 00:00:00 2001 From: C-Treff Date: Wed, 23 May 2018 10:33:56 +0200 Subject: [PATCH] time 64bit, test update 64bit settings for time is mandatory for INtime. Changed the project file. Test for ecc_test_buffers was unreliable, as the structs were not initialized befor usage. --- IDE/INTIME-RTOS/libwolfssl.vcxproj | 4 ++-- wolfcrypt/test/test.c | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/IDE/INTIME-RTOS/libwolfssl.vcxproj b/IDE/INTIME-RTOS/libwolfssl.vcxproj index 5fc200943..72bdd824c 100755 --- a/IDE/INTIME-RTOS/libwolfssl.vcxproj +++ b/IDE/INTIME-RTOS/libwolfssl.vcxproj @@ -192,7 +192,7 @@ Async - _USRDLL;WOLFSSL_DLL;BUILDING_WOLFSSL;WOLFSSL_USER_SETTINGS;%(PreprocessorDefinitions) + _USRDLL;WOLFSSL_DLL;BUILDING_WOLFSSL;WOLFSSL_USER_SETTINGS;_USE_64BIT_TIME_T;%(PreprocessorDefinitions) $(ProjectDir);$(ProjectDir)..\..\;%(AdditionalIncludeDirectories) $(IntDir) $(IntDir) @@ -211,7 +211,7 @@ Async - _USRDLL;WOLFSSL_DLL;BUILDING_WOLFSSL;WOLFSSL_USER_SETTINGS;%(PreprocessorDefinitions) + _USRDLL;WOLFSSL_DLL;BUILDING_WOLFSSL;WOLFSSL_USER_SETTINGS;_USE_64BIT_TIME_T;%(PreprocessorDefinitions) $(ProjectDir);$(ProjectDir)..\..\;%(AdditionalIncludeDirectories) $(IntDir) $(IntDir) diff --git a/wolfcrypt/test/test.c b/wolfcrypt/test/test.c index 314285f0c..4554cd83a 100644 --- a/wolfcrypt/test/test.c +++ b/wolfcrypt/test/test.c @@ -15729,6 +15729,9 @@ int ecc_test_buffers(void) { int verify = 0; word32 x; + memset(&cliKey, 0, sizeof(ecc_key)); + memset(&servKey, 0, sizeof(ecc_key)); + bytes = (size_t)sizeof_ecc_clikey_der_256; /* place client key into ecc_key struct cliKey */ ret = wc_EccPrivateKeyDecode(ecc_clikey_der_256, &idx, &cliKey,