Tock issue: infinite loop