From 2468a19c826ae0717516f5c41401680ccbda8070 Mon Sep 17 00:00:00 2001 From: Jacob Barthelmeh Date: Wed, 7 Nov 2018 14:50:07 -0700 Subject: [PATCH] static analysis fix on non default build and g++ warning --- examples/server/server.c | 2 +- wolfcrypt/src/aes.c | 2 +- wolfcrypt/src/asn.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/server/server.c b/examples/server/server.c index 48da1c392..22bdae270 100644 --- a/examples/server/server.c +++ b/examples/server/server.c @@ -832,7 +832,6 @@ THREAD_RETURN WOLFSSL_THREAD server_test(void* args) (void)updateKeysIVs; (void)postHandAuth; (void)mcastID; - (void)useX25519; (void)loadCertKeyIntoSSLObj; #ifdef WOLFSSL_TIRTOS @@ -2052,6 +2051,7 @@ exit: (void) useNtruKey; (void) ourDhParam; (void) ourCert; + (void) useX25519; #ifndef WOLFSSL_TIRTOS return 0; #endif diff --git a/wolfcrypt/src/aes.c b/wolfcrypt/src/aes.c index de0a87bef..1e768775e 100644 --- a/wolfcrypt/src/aes.c +++ b/wolfcrypt/src/aes.c @@ -8779,7 +8779,7 @@ int wc_AesGcmDecrypt(Aes* aes, byte* out, const byte* in, word32 sz, const byte* authIn, word32 authInSz) { #ifdef WOLFSSL_AESNI - int res; + int res = AES_GCM_AUTH_E; #endif /* argument checks */ diff --git a/wolfcrypt/src/asn.c b/wolfcrypt/src/asn.c index a327d060a..d5ed86b37 100644 --- a/wolfcrypt/src/asn.c +++ b/wolfcrypt/src/asn.c @@ -4982,7 +4982,7 @@ int GetAsnTimeString(void* currTime, byte* buf, word32 len) if (buf == NULL || len == 0) return BAD_FUNC_ARG; - ts = (struct tm *)XGMTIME(currTime, tmpTime); + ts = (struct tm *)XGMTIME((time_t*)currTime, tmpTime); if (ts == NULL){ WOLFSSL_MSG("failed to get time data."); return ASN_TIME_E;