Commit a9db08a6 by Eric Botcazou Committed by Eric Botcazou

Wrestrict.c (test_strcpy_range): Bump string size of one test and add dg-warning…

Wrestrict.c (test_strcpy_range): Bump string size of one test and add dg-warning for the -Wstringop-overflow warning.

	* c-c++-common/Wrestrict.c (test_strcpy_range): Bump string size of one
	test and add dg-warning for the -Wstringop-overflow warning.

From-SVN: r256764
parent 6702f18b
2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
* c-c++-common/Wrestrict.c (test_strcpy_range): Bump string size of one
test and add dg-warning for the -Wstringop-overflow warning.
2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
* c-c++-common/Warray-bounds-4.c (test_strcpy_bounds_memarray_range):
XFAIL last test on SPARC and Visium.
......
......@@ -758,7 +758,8 @@ void test_strcpy_range (void)
T (8, "012", a + r, a); /* { dg-warning "accessing 4 bytes at offsets \\\[3, \[0-9\]+] and 0 may overlap 1 byte at offset 3" "strcpy" } */
r = SR (DIFF_MAX - 2, DIFF_MAX - 1);
T (8, "012", a + r, a); /* { dg-warning "accessing 4 bytes at offsets \\\[\[0-9\]+, \[0-9\]+] and 0 overlaps" "strcpy" } */
T (8, "0123", a + r, a); /* { dg-warning "accessing 5 bytes at offsets \\\[\[0-9\]+, \[0-9\]+] and 0 overlaps" "strcpy" } */
/* { dg-warning "writing 5 bytes into a region of size 0 overflows" "memcpy" { target *-*-* } .-1 } */
/* Exercise the full range of ptrdiff_t. */
r = signed_value ();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment