From 63d5248d886c8e6ce8c675c2fc6428fe02a08c49 Mon Sep 17 00:00:00 2001 From: Jon Shallow Date: Mon, 12 Jun 2023 12:15:41 +0100 Subject: [PATCH] examples-code-check.c: Disable potential compile warning Fixes snprintf() warning of writing into smaller buffer. --- man/examples-code-check.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man/examples-code-check.c b/man/examples-code-check.c index 1d579cf2..1c741ead 100644 --- a/man/examples-code-check.c +++ b/man/examples-code-check.c @@ -576,7 +576,7 @@ int main(int argc, char* argv[]) i, (int)(sizeof(name_list)/sizeof(name_list[0]))); continue; } - snprintf(name_list[i], sizeof(name_list[i]), "%s", buffer); + memcpy(name_list[i], buffer, sizeof(name_list[i])-1); name_cnt++; }