goto done;
}
-#ifndef FREETDM_SKIP_SIG_STATES
- /* We will fail RFC's if we not skip states, but some modules apart from ftmod_sangoma_isdn
- * expect the call to always to go PROGRESS and PROGRESS MEDIA state before going to UP, so
- * remove this only in netborder branch for now while we update the sig modules */
+ if (!ftdm_test_flag(ftdmchan->span, FTDM_SPAN_USE_SKIP_STATES)) {
+ /* We will fail RFC's if we not skip states, but some modules apart from ftmod_sangoma_isdn
+ * expect the call to always to go PROGRESS and PROGRESS MEDIA state before going to UP, so
+ * use FTDM_SPAN_USE_SKIP_STATESfor now while we update the sig modules */
- if (ftdmchan->state < FTDM_CHANNEL_STATE_PROGRESS) {
- ftdm_channel_set_state(file, func, line, ftdmchan, FTDM_CHANNEL_STATE_PROGRESS, 1);
- }
+ if (ftdmchan->state < FTDM_CHANNEL_STATE_PROGRESS) {
+ ftdm_channel_set_state(file, func, line, ftdmchan, FTDM_CHANNEL_STATE_PROGRESS, 1);
+ }
- /* set state unlocks the channel so we need to re-confirm that the channel hasn't gone to hell */
- if (ftdmchan->state == FTDM_CHANNEL_STATE_TERMINATING) {
- ftdm_log_chan_msg(ftdmchan, FTDM_LOG_DEBUG, "Ignoring answer because the call has moved to TERMINATING while we're moving to PROGRESS\n");
- goto done;
- }
+ /* set state unlocks the channel so we need to re-confirm that the channel hasn't gone to hell */
+ if (ftdmchan->state == FTDM_CHANNEL_STATE_TERMINATING) {
+ ftdm_log_chan_msg(ftdmchan, FTDM_LOG_DEBUG, "Ignoring answer because the call has moved to TERMINATING while we're moving to PROGRESS\n");
+ goto done;
+ }
- if (ftdmchan->state < FTDM_CHANNEL_STATE_PROGRESS_MEDIA) {
- ftdm_channel_set_state(file, func, line, ftdmchan, FTDM_CHANNEL_STATE_PROGRESS_MEDIA, 1);
- }
+ if (ftdmchan->state < FTDM_CHANNEL_STATE_PROGRESS_MEDIA) {
+ ftdm_channel_set_state(file, func, line, ftdmchan, FTDM_CHANNEL_STATE_PROGRESS_MEDIA, 1);
+ }
- /* set state unlocks the channel so we need to re-confirm that the channel hasn't gone to hell */
- if (ftdmchan->state == FTDM_CHANNEL_STATE_TERMINATING) {
- ftdm_log_chan_msg(ftdmchan, FTDM_LOG_DEBUG, "Ignoring answer because the call has moved to TERMINATING while we're moving to UP\n");
- goto done;
+ /* set state unlocks the channel so we need to re-confirm that the channel hasn't gone to hell */
+ if (ftdmchan->state == FTDM_CHANNEL_STATE_TERMINATING) {
+ ftdm_log_chan_msg(ftdmchan, FTDM_LOG_DEBUG, "Ignoring answer because the call has moved to TERMINATING while we're moving to UP\n");
+ goto done;
+ }
}
-#endif
ftdm_channel_set_state(file, func, line, ftdmchan, FTDM_CHANNEL_STATE_UP, 1);
done: