[svn-commits] file: trunk r162205 - in /trunk: ./ main/rtp.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Dec 9 13:48:36 CST 2008


Author: file
Date: Tue Dec  9 13:48:35 2008
New Revision: 162205

URL: http://svn.digium.com/view/asterisk?view=rev&rev=162205
Log:
Merged revisions 162204 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r162204 | file | 2008-12-09 15:47:07 -0400 (Tue, 09 Dec 2008) | 7 lines
  
  Make sure that the timestamp for DTMF is not the same as the previous voice frame and do not send audio when transmitting DTMF as this confuses some equipment.
  (closes issue #13209)
  Reported by: ip-rob
  Patches:
        13209.diff uploaded by file (license 11)
  Tested by: ip-rob, bujones
........

Modified:
    trunk/   (props changed)
    trunk/main/rtp.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/main/rtp.c
URL: http://svn.digium.com/view/asterisk/trunk/main/rtp.c?view=diff&rev=162205&r1=162204&r2=162205
==============================================================================
--- trunk/main/rtp.c (original)
+++ trunk/main/rtp.c Tue Dec  9 13:48:35 2008
@@ -3050,6 +3050,7 @@
 
 	rtp->dtmfmute = ast_tvadd(ast_tvnow(), ast_tv(0, 500000));
 	rtp->send_duration = 160;
+	rtp->lastdigitts = rtp->lastts + rtp->send_duration;
 	
 	/* Get a pointer to the header */
 	rtpheader = (unsigned int *)data;
@@ -3169,10 +3170,9 @@
 				    ast_inet_ntoa(rtp->them.sin_addr),
 				    ntohs(rtp->them.sin_port), rtp->send_payload, rtp->seqno, rtp->lastdigitts, res - hdrlen);
 	}
+	rtp->lastts += rtp->send_duration;
 	rtp->sending_digit = 0;
 	rtp->send_digit = 0;
-	/* Increment lastdigitts */
-	rtp->lastdigitts += 960;
 	rtp->seqno++;
 
 	return res;
@@ -3497,6 +3497,10 @@
 	unsigned int ms;
 	int pred;
 	int mark = 0;
+
+	if (rtp->sending_digit) {
+		return 0;
+	}
 
 	ms = calc_txstamp(rtp, &f->delivery);
 	/* Default prediction */




More information about the svn-commits mailing list