From fa9b03186ac8999b3b5632cd567f18b497df22d2 Mon Sep 17 00:00:00 2001 From: Florin Apostol Date: Thu, 25 Jun 2015 15:05:20 +0100 Subject: [PATCH] dash: Correct check for valid timeShiftBufferDepth If not set, the timeShiftBufferDepth has a default value of -1. The standard says that this should be interpreted as infinite. The gst_mpd_client_check_time_position function incorrectly compares timeShiftBufferDepth with 0 instead of -1 to determine if it was set. https://bugzilla.gnome.org/show_bug.cgi?id=751500 --- ext/dash/gstmpdparser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/dash/gstmpdparser.c b/ext/dash/gstmpdparser.c index 99ee855246..b4adf5d709 100644 --- a/ext/dash/gstmpdparser.c +++ b/ext/dash/gstmpdparser.c @@ -4570,7 +4570,7 @@ gst_mpd_client_check_time_position (GstMpdClient * client, *diff = ts_microseconds - stream_now; return 1; } - if (client->mpd_node->timeShiftBufferDepth + if (client->mpd_node->timeShiftBufferDepth != -1 && ts_microseconds < stream_now - client->mpd_node->timeShiftBufferDepth) { *diff = ts_microseconds - stream_now;