]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
PR testsuite/92016 - Excess errors in Wstringop-overflow-17.c
authormsebor <msebor@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 15 Oct 2019 19:16:51 +0000 (19:16 +0000)
committermsebor <msebor@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 15 Oct 2019 19:16:51 +0000 (19:16 +0000)
gcc/testsuite/ChangeLog:
* gcc.dg/Wstringop-overflow-17.c: Expect an additional warning.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@277008 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/Wstringop-overflow-17.c

index d18f5b4a3adabcebd300a546db2232f5e4534155..730e396ccea8c31a17ea1a2a3ed9641b1bd6453a 100644 (file)
@@ -1,3 +1,8 @@
+2019-10-15  Martin Sebor  <msebor@redhat.com>
+
+       PR testsuite/92016
+       * gcc.dg/Wstringop-overflow-17.c: Expect an additional warning.
+
 2019-10-15  Bill Schmidt  <wschmidt@linux.ibm.com>
 
        PR target/92093
index de22c98c753fe793da4d1af37e2d25260c116031..fdacea3972dcd2140fc28f57e2ab2bcd8299cecc 100644 (file)
@@ -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" }
 }