adding termination service states(in-service/out-of-service) flags and

reject incoming megaco request if requested termination is not in service
This commit is contained in:
root
2012-07-30 13:17:39 -04:00
parent 5d3718fdb8
commit 0c87442dd7
5 changed files with 21 additions and 10 deletions
+5
View File
@@ -128,6 +128,8 @@ static void ctdm_report_alarms(ftdm_channel_t *channel)
switch_event_add_header_string(event, SWITCH_STACK_BOTTOM, "alarm", "general");
}
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Reporting [%s] alarms for %s:%d\n",
(alarmflag?"ftdm-alarm-clear":"ftdm-alarm-trap"), ftdm_channel_get_span_name(channel), ftdm_channel_get_id(channel));
switch_event_fire(&event);
return;
@@ -184,6 +186,9 @@ static void ctdm_event_handler(switch_event_t *event)
return;
}
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Requesting alarm status for %s:%d\n",
ftdm_channel_get_span_name(channel), ftdm_channel_get_id(channel));
ctdm_report_alarms(channel);
}
}