From 9032070deaa03431921315f973c548c2c403fecc Mon Sep 17 00:00:00 2001 From: Steve Ellcey Date: Tue, 1 Nov 2016 16:00:09 -0700 Subject: [PATCH] Fix warning from latest GCC in tst-printf.c * stdio-common/tst-printf.c: Ignore -Wformat-length warning. --- ChangeLog | 4 ++++ stdio-common/tst-printf.c | 5 +++++ 2 files changed, 9 insertions(+) diff --git a/ChangeLog b/ChangeLog index 6be5c5d67b..e16451af05 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2016-11-01 Steve Ellcey + + * stdio-common/tst-printf.c: Ignore -Wformat-length warning. + 2016-11-01 Joseph Myers [BZ #19673] diff --git a/stdio-common/tst-printf.c b/stdio-common/tst-printf.c index 2896b18ecd..ffe7ac7753 100644 --- a/stdio-common/tst-printf.c +++ b/stdio-common/tst-printf.c @@ -32,6 +32,11 @@ The compiler warnings are not useful here. */ DIAG_IGNORE_NEEDS_COMMENT (4.9, "-Wformat"); +#if __GNUC_PREREQ (7, 0) +/* Compiler warnings about format lengths should also be ignored. */ +DIAG_IGNORE_NEEDS_COMMENT (7.0, "-Wformat-length"); +#endif + static void rfg1 (void); static void rfg2 (void); static void rfg3 (void);