Added exit procedure back.