Execution of test gcc.dg/webizer.c fails with a segfault for powerpc-eabi with the GNU simulator. The test has an array of size 2 and accesses that array with indices of 1 and 2. This patch fixes the bounds of the loop index.
Tested on powerpc-none-eabi; OK for trunk? Janis
2013-01-15 Janis Johnson <jani...@codesourcery.com> * gcc.dg/webizer.c: Adjust loop variable. Index: testsuite/gcc.dg/webizer.c =================================================================== --- testsuite/gcc.dg/webizer.c (revision 195216) +++ testsuite/gcc.dg/webizer.c (working copy) @@ -21,7 +21,7 @@ configure2() { block = 0 ; - for( row = 1 ; row <= numRows ; row++ ) { + for( row = 0 ; row < numRows ; row++ ) { block++ ; if( rowArray[row].endx1 > 0 ) { block++ ;