I think that I fixed the infinite loop problem.
Please let me know if it happens again.