Clean up exec/pause/exit on event.