From ecf8e5a00e5909ae664e1fafb641ddf711210904 Mon Sep 17 00:00:00 2001 From: Detlef Riekenberg Date: Tue, 12 Apr 2022 01:06:10 +0200 Subject: [PATCH] tccelf: Avoid a compiler warning with snprintf Target buffer must be larger as the format string + the replacement for %s to avoid a warning [-Wformat-truncation=] Signed-off-by: Detlef Riekenberg --- tccelf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tccelf.c b/tccelf.c index 83146fdd..1dcbc388 100644 --- a/tccelf.c +++ b/tccelf.c @@ -3706,7 +3706,7 @@ static int ld_add_file(TCCState *s1, const char filename[]) static int ld_add_file_list(TCCState *s1, const char *cmd, int as_needed) { - char filename[1024], libname[1024]; + char filename[1024], libname[1016]; int t, group, nblibs = 0, ret = 0; char **libs = NULL;