adaptivedemux: Don't stop all tasks and streams from the update task on errors

It will deadlocks as we will then join() the update task from itself. Instead
just post an actual error message on the bus and only stop the update task.

The application is then responsible for shutting down the element, and thus
all the other tasks and everything, based on the error message it gets.
This commit is contained in:
Sebastian Dröge 2015-04-21 22:04:56 +02:00
parent 6c968ed3da
commit 3c639d3235

View file

@ -2267,7 +2267,8 @@ gst_adaptive_demux_updates_loop (GstAdaptiveDemux * demux)
g_get_monotonic_time () +
klass->get_manifest_update_interval (demux);
} else {
GST_ERROR_OBJECT (demux, "Could not update playlist");
GST_ELEMENT_ERROR (demux, STREAM, FAILED,
(_("Internal data stream error.")), ("Could not update playlist"));
goto error;
}
} else {
@ -2291,7 +2292,7 @@ quit:
error:
{
GST_DEBUG_OBJECT (demux, "Stopped updates task because of error");
gst_adaptive_demux_stop_tasks (demux);
gst_task_stop (demux->priv->updates_task);
}
}