Never send channel identifier with SETUP when GR303 CPE
git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@125 2fbb986a-6c06-0410-b554-c9c1f0a7f128
This commit is contained in:
parent
f8b7c404a0
commit
5166adfb1e
7
q931.c
7
q931.c
@ -2184,6 +2184,11 @@ int q931_setup(struct pri *pri, q931_call *c, struct pri_sr *req)
|
||||
c->userl1 = req->userl1;
|
||||
c->ds1no = (req->channel & 0xff00) >> 8;
|
||||
req->channel &= 0xff;
|
||||
if ((pri->localtype == PRI_CPE) && pri->subchannel) {
|
||||
req->channel = 0;
|
||||
req->exclusive = 0;
|
||||
}
|
||||
|
||||
c->channelno = req->channel;
|
||||
c->slotmap = -1;
|
||||
c->nonisdn = req->nonisdn;
|
||||
@ -2191,7 +2196,7 @@ int q931_setup(struct pri *pri, q931_call *c, struct pri_sr *req)
|
||||
c->complete = req->numcomplete;
|
||||
if (req->exclusive)
|
||||
c->chanflags = FLAG_EXCLUSIVE;
|
||||
else
|
||||
else if (c->channelno)
|
||||
c->chanflags = FLAG_PREFERRED;
|
||||
if (req->caller) {
|
||||
strncpy(c->callernum, req->caller, sizeof(c->callernum) - 1);
|
||||
|
Loading…
Reference in New Issue
Block a user