public virtual void OnExit() {
_running = false;
if(_xrm != null) {
_xrm.Stop();
_xrm = null;
}
ApplicationNode appnode = _app_node;
_app_node = null;
NCService ncservice = null;
if(appnode != null) {
ncservice = appnode.NCService;
}
if(ncservice != null && _node_config.NCService.Checkpointing) {
string checkpoint = ncservice.GetCheckpoint();
string prev_cp = _node_config.NCService.Checkpoint;
string empty_cp = (new Point()).ToString();
if(!checkpoint.Equals(prev_cp) && !checkpoint.Equals(empty_cp))
{
_node_config.NCService.Checkpoint = checkpoint;
_node_config.WriteConfig();
}
}
_fe_stop_pem = Brunet.Util.FuzzyTimer.Instance.DoEvery(StopPem, 500, 500);
}
}