mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-18 22:36:33 +00:00
Revert "Revert "dashdemux: fixed gst_mpd_client_advance_segment to return GST_FLOW_EOS""
This reverts commit 4875ddf585
.
This was based on a misunderstanding of the code.
https://bugzilla.gnome.org/show_bug.cgi?id=752085
This commit is contained in:
parent
34622c3961
commit
a755fbb440
1 changed files with 11 additions and 2 deletions
|
@ -3977,10 +3977,14 @@ gst_mpd_client_advance_segment (GstMpdClient * client, GstActiveStream * stream,
|
|||
}
|
||||
|
||||
if (stream->segments == NULL) {
|
||||
if (stream->segment_index < 0)
|
||||
if (stream->segment_index < 0) {
|
||||
stream->segment_index = 0;
|
||||
else
|
||||
} else {
|
||||
stream->segment_index++;
|
||||
if (segments_count > 0 && stream->segment_index >= segments_count) {
|
||||
ret = GST_FLOW_EOS;
|
||||
}
|
||||
}
|
||||
goto done;
|
||||
}
|
||||
|
||||
|
@ -4017,6 +4021,10 @@ gst_mpd_client_advance_segment (GstMpdClient * client, GstActiveStream * stream,
|
|||
if (stream->segment_repeat_index >= segment->repeat) {
|
||||
stream->segment_repeat_index = 0;
|
||||
stream->segment_index++;
|
||||
if (segments_count > 0 && stream->segment_index >= segments_count) {
|
||||
ret = GST_FLOW_EOS;
|
||||
goto done;
|
||||
}
|
||||
} else {
|
||||
stream->segment_repeat_index++;
|
||||
}
|
||||
|
@ -4024,6 +4032,7 @@ gst_mpd_client_advance_segment (GstMpdClient * client, GstActiveStream * stream,
|
|||
if (stream->segment_repeat_index == 0) {
|
||||
stream->segment_index--;
|
||||
if (stream->segment_index < 0) {
|
||||
ret = GST_FLOW_EOS;
|
||||
goto done;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue