Prevent loop indefinitely