aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2006-09-27 19:10:59 +0000
committerfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2006-09-27 19:10:59 +0000
commitdadbc871e02eaf88d368d9cc0be910b290e5f5be (patch)
treec16cef5e8f1b05aad8d600f755efcc69a2d1a803 /main
parent846bcd64b8a16c528c027b863d41264a3dccdb38 (diff)
Compensate for out of order packets better if RFC2833 compensation is turned on.
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@43798 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main')
-rw-r--r--main/rtp.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/main/rtp.c b/main/rtp.c
index 748837eee..deef1e3be 100644
--- a/main/rtp.c
+++ b/main/rtp.c
@@ -681,6 +681,12 @@ static struct ast_frame *process_rfc2833(struct ast_rtp *rtp, unsigned char *dat
f->samples = duration;
rtp->resp = 0;
rtp->lasteventendseqn = seqno;
+ } else if (ast_test_flag(rtp, FLAG_DTMF_COMPENSATE) && event_end & 0x80 && rtp->lasteventendseqn != seqno) {
+ rtp->resp = resp;
+ f = send_dtmf(rtp, AST_FRAME_DTMF_END);
+ f->samples = duration;
+ rtp->resp = 0;
+ rtp->lasteventendseqn = seqno;
}
rtp->dtmfcount = dtmftimeout;