From eb8faf2d5879d625707df06ed8bdf89e8a1afe81 Mon Sep 17 00:00:00 2001 From: Mahavir Jain Date: Tue, 4 Jun 2019 18:24:49 +0530 Subject: [PATCH] Fix few warnings resulting in build failures --- library/hmac_drbg.c | 2 +- library/x509_crt.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/library/hmac_drbg.c b/library/hmac_drbg.c index 284c9b4e96..c5a01be932 100644 --- a/library/hmac_drbg.c +++ b/library/hmac_drbg.c @@ -74,7 +74,7 @@ int mbedtls_hmac_drbg_update_ret( mbedtls_hmac_drbg_context *ctx, unsigned char rounds = ( additional != NULL && add_len != 0 ) ? 2 : 1; unsigned char sep[1]; unsigned char K[MBEDTLS_MD_MAX_SIZE]; - int ret; + int ret = 0; for( sep[0] = 0; sep[0] < rounds; sep[0]++ ) { diff --git a/library/x509_crt.c b/library/x509_crt.c index 9c2e36547e..cddb4ef53c 100644 --- a/library/x509_crt.c +++ b/library/x509_crt.c @@ -2013,7 +2013,7 @@ static int x509_crt_find_parent_in( { int ret; mbedtls_x509_crt *parent, *fallback_parent; - int signature_is_good, fallback_signature_is_good; + int signature_is_good = 0, fallback_signature_is_good; #if defined(MBEDTLS_ECDSA_C) && defined(MBEDTLS_ECP_RESTARTABLE) /* did we have something in progress? */