Correction of the loop condition.