From: Wim Taymans Date: Thu, 25 Jul 2013 20:39:04 +0000 (+0200) Subject: session: move check for is_early around X-Git-Tag: 1.1.3~40 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a3bf374351fc1e0ee578dc2f073acb9a08adcebd;p=platform%2Fupstream%2Fgst-plugins-good.git session: move check for is_early around Move the check for the early RTCP to where it is needed and used. --- diff --git a/gst/rtpmanager/rtpsession.c b/gst/rtpmanager/rtpsession.c index bc0843b..5bb0f3f 100644 --- a/gst/rtpmanager/rtpsession.c +++ b/gst/rtpmanager/rtpsession.c @@ -2939,6 +2939,11 @@ is_rtcp_time (RTPSession * sess, GstClockTime current_time, ReportData * data) { GstClockTime new_send_time, elapsed; + if (GST_CLOCK_TIME_IS_VALID (sess->next_early_rtcp_time)) + data->is_early = TRUE; + else + data->is_early = FALSE; + if (data->is_early && sess->next_early_rtcp_time < current_time) goto early; @@ -3087,11 +3092,6 @@ rtp_session_on_timeout (RTPSession * sess, GstClockTime current_time, g_hash_table_foreach_remove (sess->ssrcs[sess->mask_idx], (GHRFunc) remove_closing_sources, NULL); - if (GST_CLOCK_TIME_IS_VALID (sess->next_early_rtcp_time)) - data.is_early = TRUE; - else - data.is_early = FALSE; - /* see if we need to generate SR or RR packets */ if (is_rtcp_time (sess, current_time, &data)) { if (own->marked_bye) {