summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndoni Morales Alastruey <ylatuya@gmail.com>2013-04-08 14:04:10 +0200
committerSebastian Dröge <sebastian@centricular.com>2014-02-14 13:09:33 +0100
commit4e0fa57661e6c5aba7c4485d60dc596b991022ad (patch)
tree841f612b0a37de761b0a46ce10e61104ae2f1621
parentb264e9645ae7429dd13d410246662f39e7bb73e6 (diff)
downloadgstreamer-plugins-bad-4e0fa57661e6c5aba7c4485d60dc596b991022ad.tar.gz
hlsdemux: fix update interval with respect of the spec
-rw-r--r--ext/hls/gsthlsdemux.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/ext/hls/gsthlsdemux.c b/ext/hls/gsthlsdemux.c
index 37b03a89e..25d452742 100644
--- a/ext/hls/gsthlsdemux.c
+++ b/ext/hls/gsthlsdemux.c
@@ -74,8 +74,6 @@ enum
PROP_LAST
};
-static const float update_interval_factor[] = { 1, 0.5, 1.5, 3 };
-
#define DEFAULT_FRAGMENTS_CACHE 3
#define DEFAULT_FAILED_COUNT 3
#define DEFAULT_BITRATE_LIMIT 0.8
@@ -1191,10 +1189,10 @@ gst_hls_demux_schedule (GstHLSDemux * demux)
* 0.5 for the first attempt, 1.5 for the second, and 3.0 thereafter."
*/
count = demux->client->update_failed_count;
- if (count < 3)
- update_factor = update_interval_factor[count];
+ if (count == 0)
+ update_factor = 1.0;
else
- update_factor = update_interval_factor[3];
+ update_factor = 0.5;
/* schedule the next update using the target duration field of the
* playlist */