diff options
author | Peter Stromberg <wilfried@cvs.openbsd.org> | 2006-10-31 09:38:29 +0000 |
---|---|---|
committer | Peter Stromberg <wilfried@cvs.openbsd.org> | 2006-10-31 09:38:29 +0000 |
commit | 6391903a9e4caf3b32ac8cfe8e4e9c6139316308 (patch) | |
tree | 35bdca508801b3a3057ea7c9e85247354be59dd7 /gnu/usr.bin/gcc | |
parent | 847bfbf933be73f18fd78347cad5010cde020d8d (diff) |
Fix infinite loop when passing object with 3+ base classes by value:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18300
Needed by openoffice and boost on amd64
ok espie@ miod@
Diffstat (limited to 'gnu/usr.bin/gcc')
-rw-r--r-- | gnu/usr.bin/gcc/gcc/config/i386/i386.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/gnu/usr.bin/gcc/gcc/config/i386/i386.c b/gnu/usr.bin/gcc/gcc/config/i386/i386.c index b991ef7c543..ba0b78c822d 100644 --- a/gnu/usr.bin/gcc/gcc/config/i386/i386.c +++ b/gnu/usr.bin/gcc/gcc/config/i386/i386.c @@ -1756,11 +1756,11 @@ classify_argument (mode, type, classes, bit_offset) { tree bases = TYPE_BINFO_BASETYPES (type); int n_bases = TREE_VEC_LENGTH (bases); - int i; + int basenum; - for (i = 0; i < n_bases; ++i) + for (basenum = 0; basenum < n_bases; ++basenum) { - tree binfo = TREE_VEC_ELT (bases, i); + tree binfo = TREE_VEC_ELT (bases, basenum); int num; int offset = tree_low_cst (BINFO_OFFSET (binfo), 0) * 8; tree type = BINFO_TYPE (binfo); @@ -1844,11 +1844,11 @@ classify_argument (mode, type, classes, bit_offset) { tree bases = TYPE_BINFO_BASETYPES (type); int n_bases = TREE_VEC_LENGTH (bases); - int i; + int basenum; - for (i = 0; i < n_bases; ++i) + for (basenum = 0; basenum < n_bases; ++basenum) { - tree binfo = TREE_VEC_ELT (bases, i); + tree binfo = TREE_VEC_ELT (bases, basenum); int num; int offset = tree_low_cst (BINFO_OFFSET (binfo), 0) * 8; tree type = BINFO_TYPE (binfo); |