From: Matthias Klose Date: Mon, 26 Nov 2018 11:57:16 +0000 (+0000) Subject: test-long-names.c: Fix build with -Wformat-security. X-Git-Tag: releases/gcc-7.4.0~22 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5fb6435b8b9e80a099255009a873fdc26abfbaf7;p=thirdparty%2Fgcc.git test-long-names.c: Fix build with -Wformat-security. 2018-11-26 Matthias Klose * jit.dg/test-long-names.c: Fix build with -Wformat-security. From-SVN: r266457 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 798ad9565e5b..542a9f937235 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2018-11-26 Matthias Klose + + * jit.dg/test-long-names.c: Fix build with -Wformat-security. + 2018-11-25 Thomas Koenig Backport from trunk diff --git a/gcc/testsuite/jit.dg/test-long-names.c b/gcc/testsuite/jit.dg/test-long-names.c index 0fc7e676b397..8f4aa7e7026f 100644 --- a/gcc/testsuite/jit.dg/test-long-names.c +++ b/gcc/testsuite/jit.dg/test-long-names.c @@ -24,7 +24,7 @@ populate_name (const char *prefix, char *buffer) int i; /* Begin with the given prefix: */ - sprintf (buffer, prefix); + sprintf (buffer, "%s", prefix); /* Populate the rest of the buffer with 0123456789 repeatedly: */ for (i = strlen (prefix); i < NAME_LENGTH - 1; i++)