Fix the transmit_display function to not send DISPLAY from CPE->Network on EuroISDN

git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@321 2fbb986a-6c06-0410-b554-c9c1f0a7f128
This commit is contained in:
Matthew Fredrickson 2006-03-31 22:37:46 +00:00
parent e2091c29ef
commit 533412e361

22
q931.c
View File

@ -1060,17 +1060,19 @@ static FUNC_RECV(receive_display)
static FUNC_SEND(transmit_display) static FUNC_SEND(transmit_display)
{ {
int i; int i;
if ((pri->switchtype != PRI_SWITCH_NI1) && (pri->switchtype != PRI_SWITCH_QSIG)
&& *call->callername) { if ((pri->switchtype == PRI_SWITCH_NI1) || (pri->switchtype == PRI_SWITCH_QSIG)
i = 0; || ((pri->switchtype == PRI_SWITCH_EUROISDN_E1) && (pri->localtype == PRI_CPE)) ||
if(pri->switchtype != PRI_SWITCH_EUROISDN_E1) { !call->callername[0])
ie->data[0] = 0xb1; return 0;
++i;
} i = 0;
memcpy(ie->data + i, call->callername, strlen(call->callername)); if(pri->switchtype != PRI_SWITCH_EUROISDN_E1) {
return 2 + i + strlen(call->callername); ie->data[0] = 0xb1;
++i;
} }
return 0; memcpy(ie->data + i, call->callername, strlen(call->callername));
return 2 + i + strlen(call->callername);
} }
static FUNC_RECV(receive_progress_indicator) static FUNC_RECV(receive_progress_indicator)