From a3f75a17efd2dea75dcaa59e15e269c941084afc Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Thu, 25 Jul 2013 23:51:34 +0200 Subject: [PATCH] session: fix bandwidth calculation We iterate over all sources and the internal one is also in the hashtable so avoid adding it twice. --- gst/rtpmanager/rtpsession.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gst/rtpmanager/rtpsession.c b/gst/rtpmanager/rtpsession.c index 6a97022..e62772b 100644 --- a/gst/rtpmanager/rtpsession.c +++ b/gst/rtpmanager/rtpsession.c @@ -2464,7 +2464,7 @@ calculate_rtcp_interval (RTPSession * sess, gboolean deterministic, bandwidth = sess->bandwidth; else { /* If it is <= 0, then try to estimate the actual bandwidth */ - bandwidth = sess->source->bitrate; + bandwidth = 0; g_hash_table_foreach (sess->ssrcs[sess->mask_idx], (GHFunc) add_bitrates, &bandwidth); -- 2.7.4