diff options
author | crichter <crichter@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-07-23 11:37:50 +0000 |
---|---|---|
committer | crichter <crichter@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-07-23 11:37:50 +0000 |
commit | e29afcb66573c0d7e28b705bfba2ce25d0a8b405 (patch) | |
tree | 6503d07e96f6ce5a740775ff78aba72c3929647b /channels | |
parent | 0b42d76cc28507400096bf7eb6947e5e014ac278 (diff) |
another Fix because of r119585, this commit has broken high frequented BRI Ports, there was a possibility that a channel, that was marked as in_use would be reused later, the corresponding port could got stuck then. So it is recommended to upgrade for chan_misdn users.
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@132826 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r-- | channels/misdn/isdn_lib.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/channels/misdn/isdn_lib.c b/channels/misdn/isdn_lib.c index 82f1d8cf9..dc666cc87 100644 --- a/channels/misdn/isdn_lib.c +++ b/channels/misdn/isdn_lib.c @@ -2625,6 +2625,19 @@ static int handle_frm(msg_t *msg) make_dummy(&dummybc, stack->port, MISDN_ID_GLOBAL, stack->nt, 0); bc=&dummybc; } + + if (!bc && (frm->prim==(CC_SETUP|INDICATION)) ) { + make_dummy(&dummybc, stack->port, MISDN_ID_GLOBAL, stack->nt, 0); + dummybc.port=stack->port; + dummybc.l3_id=frm->dinfo; + bc=&dummybc; + + misdn_lib_send_event(bc,EVENT_RELEASE_COMPLETE); + + free_msg(msg); + return 1; + } + handle_frm_bc: if (bc ) { @@ -3110,7 +3123,7 @@ static int test_inuse(struct misdn_bchannel *bc) struct timeval now; gettimeofday(&now, NULL); if (!bc->in_use) { - if ( bc->last_used.tv_sec == now.tv_sec ) { + if (misdn_lib_port_is_pri(bc->port) && bc->last_used.tv_sec == now.tv_sec ) { cb_log(2,bc->port, "channel with stid:%x for one second still in use! (n:%d lu:%d)\n", bc->b_stid, now.tv_sec, bc->last_used.tv_sec); return 1; } |