[asterisk-commits] alecdavis: trunk r234897 - /trunk/main/dsp.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Dec 14 21:05:02 CST 2009


Author: alecdavis
Date: Mon Dec 14 21:04:59 2009
New Revision: 234897

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=234897
Log:
restarts busydetector (if enabled) when DTMF is received.

  (closes issue #16389)
  Reported by: alecdavis
  Tested by: alecdavis
  Patch
	dtmf_busydetector.diff.txt uploaded by alecdavis (license 585)


Modified:
    trunk/main/dsp.c

Modified: trunk/main/dsp.c
URL: http://svnview.digium.com/svn/asterisk/trunk/main/dsp.c?view=diff&rev=234897&r1=234896&r2=234897
==============================================================================
--- trunk/main/dsp.c (original)
+++ trunk/main/dsp.c Mon Dec 14 21:04:59 2009
@@ -1401,6 +1401,12 @@
 				memmove(dsp->digit_state.digits, dsp->digit_state.digits + 1, dsp->digit_state.current_digits);
 				dsp->digit_state.current_digits--;
 				dsp->dtmf_began = 0;
+
+				if (dsp->features & DSP_FEATURE_BUSY_DETECT) {
+					/* Reset Busy Detector as we have some confirmed activity */ 
+				        memset(dsp->historicsilence, 0, sizeof(dsp->historicsilence));
+					memset(dsp->historicnoise, 0, sizeof(dsp->historicnoise));
+				}
 			}
 
 			if (event) {




More information about the asterisk-commits mailing list