Fix bad loop.