projects
/
asterisk/asterisk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f7d567f
)
truncate last 200ms of DTMF-terminated recording to eliminate inband DTMF (issue...
author
Kevin P. Fleming
<kpfleming@digium.com>
Tue, 4 Oct 2005 22:35:43 +0000
(22:35 +0000)
committer
Kevin P. Fleming
<kpfleming@digium.com>
Tue, 4 Oct 2005 22:35:43 +0000
(22:35 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6717
65c4cc65
-6c06-0410-ace0-
fbb531ad65f3
res/res_agi.c
patch
|
blob
|
history
diff --git
a/res/res_agi.c
b/res/res_agi.c
index
c13eab7
..
5645b79
100755
(executable)
--- a/
res/res_agi.c
+++ b/
res/res_agi.c
@@
-962,7
+962,11
@@
static int handle_recordfile(struct ast_channel *chan, AGI *agi, int argc, char
switch(f->frametype) {
case AST_FRAME_DTMF:
if (strchr(argv[4], f->subclass)) {
- /* This is an interrupting chracter */
+ /* This is an interrupting chracter, so rewind to chop off any small
+ amount of DTMF that may have been recorded
+ */
+ ast_stream_rewind(fs, 200);
+ ast_truncstream(fs);
sample_offset = ast_tellstream(fs);
fdprintf(agi->fd, "200 result=%d (dtmf) endpos=%ld\n", f->subclass, sample_offset);
ast_closestream(fs);