From 006f2cce2eb1b73fa966fe52e75089dd5ec34912 Mon Sep 17 00:00:00 2001 From: Hanno Becker Date: Fri, 14 May 2021 04:55:35 +0100 Subject: [PATCH] Fix compile-time guard in session cache implementation Signed-off-by: Hanno Becker --- library/ssl_cache.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/library/ssl_cache.c b/library/ssl_cache.c index 1bbcc957b9..f33754798b 100644 --- a/library/ssl_cache.c +++ b/library/ssl_cache.c @@ -131,8 +131,9 @@ static int ssl_cache_pick_writing_slot( mbedtls_ssl_cache_context *cache, { #if defined(MBEDTLS_HAVE_TIME) mbedtls_time_t t = mbedtls_time( NULL ), oldest = 0; +#endif /* MBEDTLS_HAVE_TIME */ + mbedtls_ssl_cache_entry *old = NULL; -#endif int count = 0; mbedtls_ssl_cache_entry *cur, *prv;