Log Message: 
The usual idiom in C for "do this N times" is "for (i = 0; i < N; i++)",
not "for (i = 1; i < N+1; i++)".
Even if it weren't the idiom, it'd be safer, at least for unsigned
values, as, if i and N are the same width, and N has the maximum
possible value for that width, the first of those runs i from 0 to N1,
all of which fit in a variable of that width, and the second of those
runs i from 1 to N, the latter of which doesn't fit into a variable of
that width, so modulo arithmetic turns it into 0 and the loop keeps
running forever.
Fixes bug 7844.
