Add missing local variable initialization
These issues were flagged by Coverity as instances where a local
variable may be used prior to being initialized. Please note that
none of these changes fixes any particular bug, this is just an attempt
to add more robustness.
Signed-off-by: Leonid Rozenboim <leonid.rozenboim@oracle.com>
diff --git a/library/ssl_ticket.c b/library/ssl_ticket.c
index 7f65849..a9036a2 100644
--- a/library/ssl_ticket.c
+++ b/library/ssl_ticket.c
@@ -70,7 +70,7 @@
unsigned char index )
{
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
- unsigned char buf[MAX_KEY_BYTES];
+ unsigned char buf[MAX_KEY_BYTES] = {0};
mbedtls_ssl_ticket_key *key = ctx->keys + index;
#if defined(MBEDTLS_USE_PSA_CRYPTO)