Set exit flag