Don't loop when max is zero