exit is handled