From fc2d12a52f798c7a9aacbf026ec31c669c2738c6 Mon Sep 17 00:00:00 2001 From: Christopher Michael Date: Tue, 21 Sep 2021 10:18:04 -0400 Subject: [PATCH] terminology: Increase size of 'buf' to avoid possible truncated string MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Gcc warns during compile that the output may be truncated here: ../src/bin/options_colors.c:265:14: note: ‘snprintf’ output between 32 and 4127 bytes into a destination of size 4096 To fix this, let's just increase the size of 'buf' slightly. --- src/bin/options_colors.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/options_colors.c b/src/bin/options_colors.c index 5cb757c6..1d347eb2 100644 --- a/src/bin/options_colors.c +++ b/src/bin/options_colors.c @@ -255,7 +255,7 @@ options_colors(Evas_Object *opbox, Evas_Object *term) len = end - start; if (len < sizeof(theme)) { - char buf[4096]; + char buf[4096 + 1024]; strncpy(theme, start, len); theme[len] = '\0';