aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Klose <doko@ubuntu.com>2018-11-26 11:50:31 +0000
committerMatthias Klose <doko@gcc.gnu.org>2018-11-26 11:50:31 +0000
commit14c5a314c819f444abb12af5fa51577265ef8793 (patch)
tree115d7f8aace63c71d90ae6b6ff47c15024d7f836
parentf4d3e3cca5e7483dce84a8ba38203de5246a2b7b (diff)
downloadgcc-14c5a314c819f444abb12af5fa51577265ef8793.zip
gcc-14c5a314c819f444abb12af5fa51577265ef8793.tar.gz
gcc-14c5a314c819f444abb12af5fa51577265ef8793.tar.bz2
test-long-names.c: Fix build with -Wformat-security.
2018-11-26 Matthias Klose <doko@ubuntu.com> * jit.dg/test-long-names.c: Fix build with -Wformat-security. From-SVN: r266454
-rw-r--r--gcc/testsuite/ChangeLog4
-rw-r--r--gcc/testsuite/jit.dg/test-long-names.c2
2 files changed, 5 insertions, 1 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 5a4b5a2..8509216 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,7 @@
+2018-11-26 Matthias Klose <doko@ubuntu.com>
+
+ * jit.dg/test-long-names.c: Fix build with -Wformat-security.
+
2018-11-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* lib/target-supports.exp (check_compile): Handle D.
diff --git a/gcc/testsuite/jit.dg/test-long-names.c b/gcc/testsuite/jit.dg/test-long-names.c
index 0fc7e67..8f4aa7e 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++)