aboutsummaryrefslogtreecommitdiffstats
path: root/main/dsp.c
diff options
context:
space:
mode:
authoralecdavis <alecdavis@f38db490-d61c-443f-a65b-d21fe96a405b>2009-12-15 03:04:59 +0000
committeralecdavis <alecdavis@f38db490-d61c-443f-a65b-d21fe96a405b>2009-12-15 03:04:59 +0000
commit932b9ff0b2d1eef84fe5ad4b029a936e4ebafb39 (patch)
treefc2126a8279a23da8e46e442e1b94315ef4d18b5 /main/dsp.c
parentd2b7fda4975e8f1ecb0173d7bfa1241339de11c9 (diff)
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) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@234897 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/dsp.c')
-rw-r--r--main/dsp.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/main/dsp.c b/main/dsp.c
index ca30dad14..51a1f068f 100644
--- a/main/dsp.c
+++ b/main/dsp.c
@@ -1401,6 +1401,12 @@ struct ast_frame *ast_dsp_process(struct ast_channel *chan, struct ast_dsp *dsp,
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) {