From 863950d280dd0bc02edce2e88484735cea5bd1c7 Mon Sep 17 00:00:00 2001 From: Martin Sebor Date: Tue, 15 Oct 2019 19:16:51 +0000 Subject: [PATCH] PR testsuite/92016 - Excess errors in Wstringop-overflow-17.c gcc/testsuite/ChangeLog: * gcc.dg/Wstringop-overflow-17.c: Expect an additional warning. From-SVN: r277008 --- gcc/testsuite/ChangeLog | 5 +++++ gcc/testsuite/gcc.dg/Wstringop-overflow-17.c | 3 +-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index d18f5b4a3ad..730e396ccea 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2019-10-15 Martin Sebor + + PR testsuite/92016 + * gcc.dg/Wstringop-overflow-17.c: Expect an additional warning. + 2019-10-15 Bill Schmidt PR target/92093 diff --git a/gcc/testsuite/gcc.dg/Wstringop-overflow-17.c b/gcc/testsuite/gcc.dg/Wstringop-overflow-17.c index de22c98c753..fdacea3972d 100644 --- a/gcc/testsuite/gcc.dg/Wstringop-overflow-17.c +++ b/gcc/testsuite/gcc.dg/Wstringop-overflow-17.c @@ -1,12 +1,11 @@ /* Test to verify that -Wstringop-overflow mentions the referenced object - i. { dg-do compile } { dg-options "-O2 -Wall" } */ static void copy_n (char *d, const char *s, int n) { while (n--) - *d++ = *s++; + *d++ = *s++; // { dg-warning "writing 1 byte into a region of size 0" } *d = 0; // { dg-warning "writing 1 byte into a region of size 0" } } -- 2.30.2