session: fix bandwidth calculation

We iterate over all sources and the internal one is also in the
hashtable so avoid adding it twice.
This commit is contained in:
Wim Taymans 2013-07-25 23:51:34 +02:00
parent 9eaef9d332
commit a3f75a17ef

View file

@ -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);