freetdm - SS7 Support for custom SIP headers for RDNIS and Generic Number
This commit is contained in:
parent
eb1a0a395f
commit
e9f8fb4942
|
@ -1299,6 +1299,7 @@ static switch_call_cause_t channel_outgoing_channel(switch_core_session_t *sessi
|
|||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-RDNIS");
|
||||
if (sipvar) {
|
||||
ftdm_set_string(caller_data.rdnis.digits, sipvar);
|
||||
ftdm_usrmsg_add_var(&usrmsg, "ss7_rdnis_digits", sipvar);
|
||||
}
|
||||
|
||||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-RDNIS-Plan");
|
||||
|
@ -1321,6 +1322,40 @@ static switch_call_cause_t channel_outgoing_channel(switch_core_session_t *sessi
|
|||
ftdm_usrmsg_add_var(&usrmsg, "ss7_rdnis_pres_ind", sipvar);
|
||||
}
|
||||
|
||||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-GN");
|
||||
if (sipvar) {
|
||||
ftdm_usrmsg_add_var(&usrmsg, "ss7_gn_digits", sipvar);
|
||||
}
|
||||
|
||||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-GN-NumQual");
|
||||
if (sipvar) {
|
||||
ftdm_usrmsg_add_var(&usrmsg, "ss7_gn_numqual", sipvar);
|
||||
}
|
||||
|
||||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-GN-NADI");
|
||||
if (sipvar) {
|
||||
ftdm_usrmsg_add_var(&usrmsg, "ss7_gn_nadi", sipvar);
|
||||
}
|
||||
|
||||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-GN-Screen");
|
||||
if (sipvar) {
|
||||
ftdm_usrmsg_add_var(&usrmsg, "ss7_gn_screen_ind", sipvar);
|
||||
}
|
||||
|
||||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-GN-Presentation");
|
||||
if (sipvar) {
|
||||
ftdm_usrmsg_add_var(&usrmsg, "ss7_gn_pres_ind", sipvar);
|
||||
}
|
||||
|
||||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-GN-Plan");
|
||||
if (sipvar) {
|
||||
ftdm_usrmsg_add_var(&usrmsg, "ss7_gn_npi", sipvar);
|
||||
}
|
||||
|
||||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-GN-NumInComp");
|
||||
if (sipvar) {
|
||||
ftdm_usrmsg_add_var(&usrmsg, "ss7_gn_num_inc_ind", sipvar);
|
||||
}
|
||||
|
||||
sipvar = switch_channel_get_variable(channel, "sip_h_X-FreeTDM-Screen");
|
||||
if (sipvar) {
|
||||
|
@ -1604,6 +1639,41 @@ ftdm_status_t ftdm_channel_from_event(ftdm_sigmsg_t *sigmsg, switch_core_session
|
|||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-RDNIS-Presentation", "%d", channel_caller_data->rdnis.plan);
|
||||
}
|
||||
|
||||
var_value = ftdm_sigmsg_get_var(sigmsg, "ss7_gn_digits");
|
||||
if (!ftdm_strlen_zero(var_value)) {
|
||||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-GN", "%d", var_value);
|
||||
|
||||
var_value = ftdm_sigmsg_get_var(sigmsg, "ss7_gn_numqual");
|
||||
if (!ftdm_strlen_zero(var_value)) {
|
||||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-GN-NumQual", "%d", var_value);
|
||||
}
|
||||
|
||||
var_value = ftdm_sigmsg_get_var(sigmsg, "ss7_gn_nadi");
|
||||
if (!ftdm_strlen_zero(var_value)) {
|
||||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-GN-NADI", "%d", var_value);
|
||||
}
|
||||
|
||||
var_value = ftdm_sigmsg_get_var(sigmsg, "ss7_gn_screen_ind");
|
||||
if (!ftdm_strlen_zero(var_value)) {
|
||||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-GN-Screen", "%d", var_value);
|
||||
}
|
||||
|
||||
var_value = ftdm_sigmsg_get_var(sigmsg, "ss7_gn_pres_ind");
|
||||
if (!ftdm_strlen_zero(var_value)) {
|
||||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-GN-Presentation", "%d", var_value);
|
||||
}
|
||||
|
||||
var_value = ftdm_sigmsg_get_var(sigmsg, "ss7_gn_npi");
|
||||
if (!ftdm_strlen_zero(var_value)) {
|
||||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-GN-Plan", "%d", var_value);
|
||||
}
|
||||
|
||||
var_value = ftdm_sigmsg_get_var(sigmsg, "ss7_gn_num_inc_ind");
|
||||
if (!ftdm_strlen_zero(var_value)) {
|
||||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-GN-NumInComp", "%d", var_value);
|
||||
}
|
||||
} /* End - var_value = ftdm_sigmsg_get_var(sigmsg, "ss7_gn_digits"); */
|
||||
|
||||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-Screen", "%d", channel_caller_data->screen);
|
||||
switch_channel_set_variable_printf(channel, "sip_h_X-FreeTDM-Presentation", "%d", channel_caller_data->pres);
|
||||
}
|
||||
|
|
|
@ -154,11 +154,11 @@ ftdm_status_t copy_cdPtyNum_to_sngss7(ftdm_channel_t *ftdmchan, SiCdPtyNum *cdPt
|
|||
cdPtyNum->natAddrInd.pres = PRSNT_NODEF;
|
||||
cld_nadi = ftdm_usrmsg_get_var(ftdmchan->usrmsg, "ss7_cld_nadi");
|
||||
if (!ftdm_strlen_zero(cld_nadi)) {
|
||||
SS7_DEBUG_CHAN(ftdmchan,"Found user supplied Called NADI value \"%s\"\n", cld_nadi);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Called NADI value \"%s\"\n", cld_nadi);
|
||||
cdPtyNum->natAddrInd.val = atoi(cld_nadi);
|
||||
} else {
|
||||
cdPtyNum->natAddrInd.val = g_ftdm_sngss7_data.cfg.isupCkt[sngss7_info->circuit->id].cld_nadi;
|
||||
SS7_DEBUG_CHAN(ftdmchan,"No user supplied NADI value found for CLD, using \"%d\"\n", cdPtyNum->natAddrInd.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "No user supplied NADI value found for CLD, using \"%d\"\n", cdPtyNum->natAddrInd.val);
|
||||
}
|
||||
|
||||
cdPtyNum->numPlan.pres = PRSNT_NODEF;
|
||||
|
@ -178,12 +178,12 @@ ftdm_status_t copy_genNmb_to_sngss7(ftdm_channel_t *ftdmchan, SiGenNum *genNmb)
|
|||
|
||||
val = ftdm_usrmsg_get_var(ftdmchan->usrmsg, "ss7_gn_digits");
|
||||
if (!ftdm_strlen_zero(val)) {
|
||||
SS7_DEBUG_CHAN(ftdmchan,"Found user supplied Generic Number qualifier \"%s\"\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Generic Number qualifier \"%s\"\n", val);
|
||||
if (copy_tknStr_to_sngss7((char*)val, &genNmb->addrSig, &genNmb->oddEven) != FTDM_SUCCESS) {
|
||||
return FTDM_FAIL;
|
||||
}
|
||||
} else {
|
||||
SS7_DEBUG_CHAN(ftdmchan,"No user supplied Generic Number qualifier \"%s\"\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "No user supplied Generic Number qualifier \"%s\"\n", val);
|
||||
return FTDM_SUCCESS;
|
||||
}
|
||||
genNmb->eh.pres = PRSNT_NODEF;
|
||||
|
@ -192,56 +192,56 @@ ftdm_status_t copy_genNmb_to_sngss7(ftdm_channel_t *ftdmchan, SiGenNum *genNmb)
|
|||
genNmb->nmbQual.pres = PRSNT_NODEF;
|
||||
val = ftdm_usrmsg_get_var(ftdmchan->usrmsg, "ss7_gn_numqual");
|
||||
if (!ftdm_strlen_zero(val)) {
|
||||
SS7_DEBUG_CHAN(ftdmchan,"Found user supplied Generic Number \"number qualifier\" \"%s\"\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Generic Number \"%s\"\n", val);
|
||||
genNmb->nmbQual.val = atoi(val);
|
||||
} else {
|
||||
genNmb->nmbQual.val = g_ftdm_sngss7_data.cfg.isupCkt[sngss7_info->circuit->id].gn_nmbqual;
|
||||
SS7_DEBUG_CHAN(ftdmchan,"No user supplied Generic Number \"number qualifier\" \"%d\"\n", genNmb->nmbQual.val);
|
||||
ftdm_log_chan_msg(ftdmchan, FTDM_LOG_DEBUG, "No user supplied Generic Number \n");
|
||||
}
|
||||
genNmb->natAddrInd.pres = PRSNT_NODEF;
|
||||
val = ftdm_usrmsg_get_var(ftdmchan->usrmsg, "ss7_gn_nadi");
|
||||
if (!ftdm_strlen_zero(val)) {
|
||||
SS7_DEBUG_CHAN(ftdmchan,"Found user supplied Generic Number \"nature of address\" \"%s\"\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Generic Number \"nature of address\" \"%s\"\n", val);
|
||||
genNmb->natAddrInd.val = atoi(val);
|
||||
} else {
|
||||
genNmb->natAddrInd.val = g_ftdm_sngss7_data.cfg.isupCkt[sngss7_info->circuit->id].gn_nadi;
|
||||
SS7_DEBUG_CHAN(ftdmchan,"No user supplied Generic Number \"nature of address\" \"%d\"\n", genNmb->natAddrInd.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "No user supplied Generic Number \"nature of address\" \"%d\"\n", genNmb->natAddrInd.val);
|
||||
}
|
||||
genNmb->scrnInd.pres = PRSNT_NODEF;
|
||||
val = ftdm_usrmsg_get_var(ftdmchan->usrmsg, "ss7_gn_screen_ind");
|
||||
if (!ftdm_strlen_zero(val)) {
|
||||
SS7_DEBUG_CHAN(ftdmchan,"Found user supplied Generic Number \"screening indicator\" \"%s\"\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Generic Number \"screening indicator\" \"%s\"\n", val);
|
||||
genNmb->scrnInd.val = atoi(val);
|
||||
} else {
|
||||
genNmb->natAddrInd.val = g_ftdm_sngss7_data.cfg.isupCkt[sngss7_info->circuit->id].gn_screen_ind;
|
||||
SS7_DEBUG_CHAN(ftdmchan,"No user supplied Generic Number \"screening indicator\" \"%d\"\n", genNmb->natAddrInd.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "No user supplied Generic Number \"screening indicator\" \"%d\"\n", genNmb->natAddrInd.val);
|
||||
}
|
||||
genNmb->presRest.pres = PRSNT_NODEF;
|
||||
val = ftdm_usrmsg_get_var(ftdmchan->usrmsg, "ss7_gn_pres_ind");
|
||||
if (!ftdm_strlen_zero(val)) {
|
||||
SS7_DEBUG_CHAN(ftdmchan,"Found user supplied Generic Number \"presentation indicator\" \"%s\"\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Generic Number \"presentation indicator\" \"%s\"\n", val);
|
||||
genNmb->presRest.val = atoi(val);
|
||||
} else {
|
||||
genNmb->presRest.val = g_ftdm_sngss7_data.cfg.isupCkt[sngss7_info->circuit->id].gn_pres_ind;
|
||||
SS7_DEBUG_CHAN(ftdmchan,"No user supplied Generic Number \"presentation indicator\" \"%d\"\n", genNmb->presRest.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "No user supplied Generic Number \"presentation indicator\" \"%d\"\n", genNmb->presRest.val);
|
||||
}
|
||||
genNmb->numPlan.pres = PRSNT_NODEF;
|
||||
val = ftdm_usrmsg_get_var(ftdmchan->usrmsg, "ss7_gn_npi");
|
||||
if (!ftdm_strlen_zero(val)) {
|
||||
SS7_DEBUG_CHAN(ftdmchan,"Found user supplied Generic Number \"numbering plan\" \"%s\"\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Generic Number \"numbering plan\" \"%s\"\n", val);
|
||||
genNmb->numPlan.val = atoi(val);
|
||||
} else {
|
||||
genNmb->numPlan.val = g_ftdm_sngss7_data.cfg.isupCkt[sngss7_info->circuit->id].gn_npi;
|
||||
SS7_DEBUG_CHAN(ftdmchan,"No user supplied Generic Number \"numbering plan\" \"%d\"\n", genNmb->numPlan.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "No user supplied Generic Number \"numbering plan\" \"%d\"\n", genNmb->numPlan.val);
|
||||
}
|
||||
genNmb->niInd.pres = PRSNT_NODEF;
|
||||
val = ftdm_usrmsg_get_var(ftdmchan->usrmsg, "ss7_gn_num_inc_ind");
|
||||
if (!ftdm_strlen_zero(val)) {
|
||||
SS7_DEBUG_CHAN(ftdmchan,"Found user supplied Generic Number \"number incomplete indicator\" \"%s\"\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Generic Number \"number incomplete indicator\" \"%s\"\n", val);
|
||||
genNmb->niInd.val = atoi(val);
|
||||
} else {
|
||||
genNmb->niInd.val = g_ftdm_sngss7_data.cfg.isupCkt[sngss7_info->circuit->id].gn_num_inc_ind;
|
||||
SS7_DEBUG_CHAN(ftdmchan,"No user supplied Generic Number \"number incomplete indicator\" \"%d\"\n", genNmb->niInd.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "No user supplied Generic Number \"number incomplete indicator\" \"%d\"\n", genNmb->niInd.val);
|
||||
}
|
||||
SS7_FUNC_TRACE_EXIT(__FUNCTION__);
|
||||
return FTDM_SUCCESS;
|
||||
|
@ -267,7 +267,7 @@ ftdm_status_t copy_genNmb_from_sngss7(ftdm_channel_t *ftdmchan, SiGenNum *genNmb
|
|||
|
||||
if (genNmb->nmbQual.pres == PRSNT_NODEF) {
|
||||
snprintf(val, sizeof(val), "%d", genNmb->nmbQual.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Generic Number \"number qualifier\" \"%s\"\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Generic Number \"number qualifier\" \n", val);
|
||||
sngss7_add_var(sngss7_info, "ss7_gn_numqual", val);
|
||||
}
|
||||
|
||||
|
@ -310,11 +310,22 @@ ftdm_status_t copy_redirgNum_to_sngss7(ftdm_channel_t *ftdmchan, SiRedirNum *red
|
|||
const char* val = NULL;
|
||||
sngss7_chan_data_t *sngss7_info = ftdmchan->call_data;
|
||||
ftdm_caller_data_t *caller_data = &ftdmchan->caller_data;
|
||||
uint8_t len = strlen(caller_data->rdnis.digits);
|
||||
if (!len) {
|
||||
|
||||
val = ftdm_usrmsg_get_var(ftdmchan->usrmsg, "ss7_rdnis_digits");
|
||||
if (!ftdm_strlen_zero(val)) {
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Redirection Number\"%s\"\n", val);
|
||||
if (copy_tknStr_to_sngss7((char*)val, &redirgNum->addrSig, &redirgNum->oddEven) != FTDM_SUCCESS) {
|
||||
return FTDM_FAIL;
|
||||
}
|
||||
} else if (!ftdm_strlen_zero(caller_data->rdnis.digits)) {
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Found user supplied Redirection Number\"%s\"\n", val);
|
||||
if (copy_tknStr_to_sngss7(caller_data->rdnis.digits, &redirgNum->addrSig, &redirgNum->oddEven) != FTDM_SUCCESS) {
|
||||
return FTDM_FAIL;
|
||||
}
|
||||
} else {
|
||||
ftdm_log_chan_msg(ftdmchan, FTDM_LOG_DEBUG, "No user supplied Redirection Number\n");
|
||||
return FTDM_SUCCESS;
|
||||
}
|
||||
SS7_DEBUG_CHAN(ftdmchan, "Redirecting Number %s\n", caller_data->rdnis.digits);
|
||||
|
||||
redirgNum->eh.pres = PRSNT_NODEF;
|
||||
|
||||
|
@ -327,7 +338,7 @@ ftdm_status_t copy_redirgNum_to_sngss7(ftdm_channel_t *ftdmchan, SiRedirNum *red
|
|||
} else {
|
||||
redirgNum->natAddr.val = g_ftdm_sngss7_data.cfg.isupCkt[sngss7_info->circuit->id].rdnis_nadi;
|
||||
}
|
||||
SS7_DEBUG_CHAN(ftdmchan, "Redirecting Number NADI:%d\n", redirgNum->natAddr.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Redirecting Number NADI:%d\n", redirgNum->natAddr.val);
|
||||
|
||||
/* Screening indicator */
|
||||
redirgNum->scrInd.pres = PRSNT_NODEF;
|
||||
|
@ -337,7 +348,7 @@ ftdm_status_t copy_redirgNum_to_sngss7(ftdm_channel_t *ftdmchan, SiRedirNum *red
|
|||
} else {
|
||||
redirgNum->scrInd.val = FTDM_SCREENING_VERIFIED_PASSED;
|
||||
}
|
||||
SS7_DEBUG_CHAN(ftdmchan, "Redirecting Number Screening Ind:%d\n", redirgNum->scrInd.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Redirecting Number Screening Ind:%d\n", redirgNum->scrInd.val);
|
||||
|
||||
/* Address presentation restricted ind */
|
||||
redirgNum->presRest.pres = PRSNT_NODEF;
|
||||
|
@ -348,7 +359,7 @@ ftdm_status_t copy_redirgNum_to_sngss7(ftdm_channel_t *ftdmchan, SiRedirNum *red
|
|||
} else {
|
||||
redirgNum->presRest.val = FTDM_PRES_ALLOWED;
|
||||
}
|
||||
SS7_DEBUG_CHAN(ftdmchan, "Redirecting Number Address Presentation Restricted Ind:%d\n", redirgNum->presRest.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Redirecting Number Address Presentation Restricted Ind:%d\n", redirgNum->presRest.val);
|
||||
|
||||
/* Numbering plan */
|
||||
redirgNum->numPlan.pres = PRSNT_NODEF;
|
||||
|
@ -360,7 +371,7 @@ ftdm_status_t copy_redirgNum_to_sngss7(ftdm_channel_t *ftdmchan, SiRedirNum *red
|
|||
redirgNum->numPlan.val = caller_data->rdnis.plan;
|
||||
}
|
||||
|
||||
SS7_DEBUG_CHAN(ftdmchan, "Redirecting Number Numbering plan:%d\n", redirgNum->numPlan.val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Redirecting Number Numbering plan:%d\n", redirgNum->numPlan.val);
|
||||
|
||||
return copy_tknStr_to_sngss7(caller_data->rdnis.digits, &redirgNum->addrSig, &redirgNum->oddEven);
|
||||
}
|
||||
|
@ -379,6 +390,9 @@ ftdm_status_t copy_redirgNum_from_sngss7(ftdm_channel_t *ftdmchan, SiRedirNum *r
|
|||
copy_tknStr_from_sngss7(redirgNum->addrSig, ftdmchan->caller_data.rdnis.digits, redirgNum->oddEven);
|
||||
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Redirecting Number:%s\n", ftdmchan->caller_data.rdnis.digits);
|
||||
snprintf(val, sizeof(val), "%s", ftdmchan->caller_data.rdnis.digits);
|
||||
sngss7_add_var(sngss7_info, "ss7_rdnis_digits", val);
|
||||
|
||||
|
||||
if (redirgNum->natAddr.pres == PRSNT_NODEF) {
|
||||
snprintf(val, sizeof(val), "%d", redirgNum->natAddr.val);
|
||||
|
@ -389,19 +403,19 @@ ftdm_status_t copy_redirgNum_from_sngss7(ftdm_channel_t *ftdmchan, SiRedirNum *r
|
|||
|
||||
if (redirgNum->scrInd.pres == PRSNT_NODEF) {
|
||||
snprintf(val, sizeof(val), "%d", redirgNum->scrInd.val);
|
||||
SS7_DEBUG_CHAN(ftdmchan, "Redirecting Number Screening Ind:%s\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Redirecting Number Screening Ind:%s\n", val);
|
||||
sngss7_add_var(sngss7_info, "ss7_rdnis_screen_ind", val);
|
||||
}
|
||||
|
||||
if (redirgNum->presRest.pres == PRSNT_NODEF) {
|
||||
snprintf(val, sizeof(val), "%d", redirgNum->presRest.val);
|
||||
SS7_DEBUG_CHAN(ftdmchan, "Redirecting Number Presentation Ind:%s\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Redirecting Number Presentation Ind:%s\n", val);
|
||||
sngss7_add_var(sngss7_info, "ss7_rdnis_pres_ind", val);
|
||||
}
|
||||
|
||||
if (redirgNum->numPlan.pres == PRSNT_NODEF) {
|
||||
snprintf(val, sizeof(val), "%d", redirgNum->numPlan.val);
|
||||
SS7_DEBUG_CHAN(ftdmchan, "Redirecting Number Numbering plan:%s\n", val);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Redirecting Number Numbering plan:%s\n", val);
|
||||
sngss7_add_var(sngss7_info, "ss7_rdnis_plan", val);
|
||||
caller_data->rdnis.plan = redirgNum->numPlan.val;
|
||||
}
|
||||
|
@ -583,7 +597,7 @@ int check_for_state_change(ftdm_channel_t *ftdmchan)
|
|||
|
||||
if (ftdm_test_flag(ftdmchan, FTDM_CHANNEL_STATE_CHANGE)) {
|
||||
/* the flag is still up...so we have a problem */
|
||||
SS7_DEBUG_CHAN(ftdmchan, "FTDM_CHANNEL_STATE_CHANGE flag set for over 500ms, channel state = %s\n",
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "FTDM_CHANNEL_STATE_CHANGE flag set for over 500ms, channel state = %s\n",
|
||||
ftdm_channel_state2str (ftdmchan->state));
|
||||
|
||||
return 1;
|
||||
|
@ -1625,7 +1639,7 @@ void sngss7_set_sig_status(sngss7_chan_data_t *sngss7_info, ftdm_signaling_statu
|
|||
ftdm_sigmsg_t sig;
|
||||
ftdm_channel_t *ftdmchan = sngss7_info->ftdmchan;
|
||||
|
||||
SS7_DEBUG_CHAN(ftdmchan, "Signalling link status changed to %s\n",
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "Signalling link status changed to %s\n",
|
||||
ftdm_signaling_status2str(status));
|
||||
|
||||
memset(&sig, 0, sizeof(sig));
|
||||
|
@ -1679,12 +1693,12 @@ ftdm_status_t check_for_reconfig_flag(ftdm_span_t *ftdmspan)
|
|||
|
||||
/* check if the interface is paused or resumed */
|
||||
if (sngss7_test_flag(sngss7_intf, SNGSS7_PAUSED)) {
|
||||
SS7_DEBUG_CHAN(ftdmchan, "ISUP intf %d is PAUSED\n", sngss7_intf->id);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "ISUP intf %d is PAUSED\n", sngss7_intf->id);
|
||||
/* throw the pause flag */
|
||||
sngss7_clear_ckt_flag(sngss7_info, FLAG_INFID_RESUME);
|
||||
sngss7_set_ckt_flag(sngss7_info, FLAG_INFID_PAUSED);
|
||||
} else {
|
||||
SS7_DEBUG_CHAN(ftdmchan, "ISUP intf %d is RESUMED\n", sngss7_intf->id);
|
||||
ftdm_log_chan(ftdmchan, FTDM_LOG_DEBUG, "ISUP intf %d is RESUMED\n", sngss7_intf->id);
|
||||
/* throw the resume flag */
|
||||
sngss7_clear_ckt_flag(sngss7_info, FLAG_INFID_PAUSED);
|
||||
sngss7_set_ckt_flag(sngss7_info, FLAG_INFID_RESUME);
|
||||
|
|
Loading…
Reference in New Issue