diff --git a/subprojects/gst-plugins-good/ext/adaptivedemux2/gstadaptivedemux.c b/subprojects/gst-plugins-good/ext/adaptivedemux2/gstadaptivedemux.c index 8925454264..9d4186fca5 100644 --- a/subprojects/gst-plugins-good/ext/adaptivedemux2/gstadaptivedemux.c +++ b/subprojects/gst-plugins-good/ext/adaptivedemux2/gstadaptivedemux.c @@ -1316,8 +1316,8 @@ gst_adaptive_demux_start_new_period (GstAdaptiveDemux * demux) } if (demux->input_period) { - GST_DEBUG_OBJECT (demux, "Closing previous period"); - demux->input_period->closed = TRUE; + GST_DEBUG_OBJECT (demux, "Marking that previous period has a next one"); + demux->input_period->has_next_period = TRUE; } GST_DEBUG_OBJECT (demux, "Setting up new period"); @@ -3605,7 +3605,7 @@ restart: goto restart; if (global_output_position == GST_CLOCK_STIME_NONE - && demux->output_period->closed) { + && demux->output_period->has_next_period) { GST_DEBUG_OBJECT (demux, "Period %d is drained, switching to next period", demux->output_period->period_num); if (!gst_adaptive_demux_advance_output_period (demux)) { diff --git a/subprojects/gst-plugins-good/ext/adaptivedemux2/gstadaptivedemux.h b/subprojects/gst-plugins-good/ext/adaptivedemux2/gstadaptivedemux.h index 498b983ca7..c0b6a1b762 100644 --- a/subprojects/gst-plugins-good/ext/adaptivedemux2/gstadaptivedemux.h +++ b/subprojects/gst-plugins-good/ext/adaptivedemux2/gstadaptivedemux.h @@ -375,8 +375,8 @@ struct _GstAdaptiveDemuxPeriod gboolean prepared; - /* TRUE if the period no longer receives any data (i.e. it is closed) */ - gboolean closed; + /* TRUE if there is another period after this one */ + gboolean has_next_period; /* An increasing unique identifier for the period. *