Avoid infinite loop in CRON