Keep a list of running children, and in each loop in main_loop(),