[asterisk-commits] rmudgett: branch 1.6.2 r313189 - in /branches/1.6.2: ./ channels/chan_dahdi.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon Apr 11 10:33:00 CDT 2011
Author: rmudgett
Date: Mon Apr 11 10:32:53 2011
New Revision: 313189
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=313189
Log:
Merged revisions 313188 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r313188 | rmudgett | 2011-04-11 10:27:52 -0500 (Mon, 11 Apr 2011) | 25 lines
Stuck channel using FEATD_MF if caller hangs up at the right time.
The cause was actually a caller hanging up just at the end of the Feature
Group D DTMF tones that setup the call. The reason for this is a "guard
timer" that's implemented using ast_safe_sleep(100). If the caller
happens to hang up AFTER the final tone of the DTMF string but BEFORE the
end of that ast_safe_sleep(), then ast_safe_sleep() will return non-zero.
This causes the code to bounce to the end of ss_thread(), but it does NOT
tear down the call properly.
This should be a rare occurrence because the caller has to hang up at
EXACTLY the right time. Nonetheless, it was happening quite regularly on
the reporter's system. It's not easily reproducible, unless you purposely
increase the guard-time to 2000 or more. Once you do that, you can
reproduce it every time by watching the DTMF debug and hanging up just as
it ends.
Simply add an ast_hangup() before goto quit.
(closes issue #15671)
Reported by: jcromes
Patches:
issue15671.patch uploaded by pabelanger (license 224)
Tested by: jcromes
........
Modified:
branches/1.6.2/ (props changed)
branches/1.6.2/channels/chan_dahdi.c
Propchange: branches/1.6.2/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.
Modified: branches/1.6.2/channels/chan_dahdi.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.6.2/channels/chan_dahdi.c?view=diff&rev=313189&r1=313188&r2=313189
==============================================================================
--- branches/1.6.2/channels/chan_dahdi.c (original)
+++ branches/1.6.2/channels/chan_dahdi.c Mon Apr 11 10:32:53 2011
@@ -8474,7 +8474,10 @@
/* some switches require a minimum guard time between
the last FGD wink and something that answers
immediately. This ensures it */
- if (ast_safe_sleep(chan,100)) goto quit;
+ if (ast_safe_sleep(chan, 100)) {
+ ast_hangup(chan);
+ goto quit;
+ }
}
dahdi_enable_ec(p);
if (NEED_MFDETECT(p)) {
More information about the asterisk-commits
mailing list