fix infinite loop if CONT signal received while todo is empty