From d040eb823e6a3faad30762927f899fa934225b28 Mon Sep 17 00:00:00 2001 From: Valerio Setti Date: Tue, 16 Dec 2025 14:43:28 +0100 Subject: [PATCH] include: debug: fix guards for MBEDTLS_SSL_DEBUG_CRT Guards for "mbedtls_debug_print_crt()" were updated in previous commit, but those changes were not applied to MBEDTLS_SSL_DEBUG_CRT therefore causing build failures in the CI. This commit fixes the problem. Signed-off-by: Valerio Setti --- include/mbedtls/debug.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/include/mbedtls/debug.h b/include/mbedtls/debug.h index bdfc597e0c..ecab1023f9 100644 --- a/include/mbedtls/debug.h +++ b/include/mbedtls/debug.h @@ -28,14 +28,13 @@ #define MBEDTLS_SSL_DEBUG_BUF(level, text, buf, len) \ mbedtls_debug_print_buf(ssl, level, __FILE__, __LINE__, text, buf, len) -#if defined(MBEDTLS_X509_CRT_PARSE_C) -#if !defined(MBEDTLS_X509_REMOVE_INFO) +#if defined(MBEDTLS_X509_CRT_PARSE_C) && !defined(MBEDTLS_X509_REMOVE_INFO) && \ + defined(MBEDTLS_PK_WRITE_C) #define MBEDTLS_SSL_DEBUG_CRT(level, text, crt) \ mbedtls_debug_print_crt(ssl, level, __FILE__, __LINE__, text, crt) #else #define MBEDTLS_SSL_DEBUG_CRT(level, text, crt) do { } while (0) -#endif /* MBEDTLS_X509_REMOVE_INFO */ -#endif /* MBEDTLS_X509_CRT_PARSE_C */ +#endif /* MBEDTLS_X509_CRT_PARSE_C && !MBEDTLS_X509_REMOVE_INFO && MBEDTLS_PK_WRITE_C */ #else /* MBEDTLS_DEBUG_C */