try to avoid seeing stale state when deciding if we can kill or not by updating the state in the loop rather than just at the start