[Freeswitch-svn] [commit] r11338 - freeswitch/trunk/src

FreeSWITCH SVN brian at freeswitch.org
Wed Jan 21 12:47:52 PST 2009


Author: brian
Date: Wed Jan 21 14:47:52 2009
New Revision: 11338

Log:
We should only reset sanity if we did NOT ignore the previous packet.

Modified:
   freeswitch/trunk/src/switch_rtp.c

Modified: freeswitch/trunk/src/switch_rtp.c
==============================================================================
--- freeswitch/trunk/src/switch_rtp.c	(original)
+++ freeswitch/trunk/src/switch_rtp.c	Wed Jan 21 14:47:52 2009
@@ -1590,13 +1590,16 @@
 			if (in_digit_seq > rtp_session->dtmf_data.in_digit_seq) {
 
 				rtp_session->dtmf_data.in_digit_seq = in_digit_seq;
-				rtp_session->dtmf_data.in_digit_sanity = 2000;
 #ifdef DEBUG_2833
 				
 				printf("read: %c %u %u %u %u %d %d %s\n", 
 					   key, in_digit_seq, rtp_session->dtmf_data.in_digit_seq, 
 					   ts, duration, rtp_session->recv_msg.header.m, end, end && !rtp_session->dtmf_data.in_digit_ts ? "ignored" : "");
 #endif
+				/* only set sanity if we do NOT ignore the packet */
+				if (rtp_session->dtmf_data.in_digit_ts) {
+					rtp_session->dtmf_data.in_digit_sanity = 2000;
+				}
 
 				if (rtp_session->dtmf_data.last_duration > duration && ts == rtp_session->dtmf_data.in_digit_ts) {
 					rtp_session->dtmf_data.flip++;



More information about the Freeswitch-svn mailing list