From c25dcf284a2734c9d92024d4b70ba5844d239aa2 Mon Sep 17 00:00:00 2001 From: Alexey Lapshin Date: Wed, 30 Apr 2025 18:42:01 +0700 Subject: [PATCH] fix(log): fix string size to include NUL --- components/log/src/log_format_text.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/log/src/log_format_text.c b/components/log/src/log_format_text.c index b1f7819970..21172f1f9f 100644 --- a/components/log/src/log_format_text.c +++ b/components/log/src/log_format_text.c @@ -28,7 +28,7 @@ static __attribute__((unused)) const char s_lvl_name[ESP_LOG_MAX] = { 'V', // VERBOSE }; -static __attribute__((unused)) const char s_lvl_color[ESP_LOG_MAX][8] = { +static __attribute__((unused)) const char s_lvl_color[ESP_LOG_MAX][9] = { "\0", // NONE LOG_ANSI_COLOR_REGULAR(LOG_ANSI_COLOR_RED)"\0", // ERROR LOG_ANSI_COLOR_REGULAR(LOG_ANSI_COLOR_YELLOW)"\0", // WARNING