]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-8130 don't skip delta on video unless it was less than 1 second worth to prevent...
authorAnthony Minessale <anthm@freeswitch.org>
Fri, 18 Sep 2015 15:06:41 +0000 (10:06 -0500)
committerAnthony Minessale <anthm@freeswitch.org>
Fri, 18 Sep 2015 15:06:47 +0000 (10:06 -0500)
src/switch_rtp.c

index 46ddbb7964f641a7080b16e0172ad8a4483cc22d..ad2e934cf3cce53614783ab27e29ad8c7e5492a9 100644 (file)
@@ -7050,7 +7050,10 @@ static int rtp_common_write(switch_rtp_t *rtp_session,
                        if (switch_rtp_test_flag(rtp_session, SWITCH_RTP_FLAG_GEN_TS_DELTA)) {
                                int32_t delta = (int32_t) (ntohl(send_msg->header.ts) - rtp_session->ts_norm.last_frame);
                        
-                               rtp_session->ts_norm.delta = delta;
+                               if (switch_rtp_test_flag(rtp_session, SWITCH_RTP_FLAG_VIDEO) && delta > 0 && delta < 90000) {
+                                       rtp_session->ts_norm.delta = delta;
+                               }
+                               
                                rtp_session->ts_norm.ts += rtp_session->ts_norm.delta;
                        } else {
                                switch_core_timer_sync(&rtp_session->timer);