mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 09:10:36 +00:00
mpdparser: Fix off-by-one in has-next-segment calculation
This commit is contained in:
parent
a78c1bdad5
commit
07d27d906a
1 changed files with 1 additions and 1 deletions
|
@ -3948,7 +3948,7 @@ gst_mpd_client_has_next_segment (GstMpdClient * client,
|
||||||
if (forward) {
|
if (forward) {
|
||||||
guint segments_count = gst_mpd_client_get_segments_counts (client, stream);
|
guint segments_count = gst_mpd_client_get_segments_counts (client, stream);
|
||||||
|
|
||||||
if (segments_count > 0 && stream->segment_index >= segments_count)
|
if (segments_count > 0 && stream->segment_index + 1 >= segments_count)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
} else {
|
} else {
|
||||||
if (stream->segment_index < 0)
|
if (stream->segment_index < 0)
|
||||||
|
|
Loading…
Reference in a new issue