mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-17 03:35:21 +00:00
decodebin: Hold the expose lock when freeing a chain
https://bugzilla.gnome.org/show_bug.cgi?id=700342
This commit is contained in:
parent
af24e23880
commit
83f2476976
1 changed files with 4 additions and 0 deletions
|
@ -4410,10 +4410,12 @@ gst_decode_bin_change_state (GstElement * element, GstStateChange transition)
|
|||
break;
|
||||
case GST_STATE_CHANGE_READY_TO_PAUSED:
|
||||
/* Make sure we've cleared all existing chains */
|
||||
EXPOSE_LOCK (dbin);
|
||||
if (dbin->decode_chain) {
|
||||
gst_decode_chain_free (dbin->decode_chain);
|
||||
dbin->decode_chain = NULL;
|
||||
}
|
||||
EXPOSE_UNLOCK (dbin);
|
||||
DYN_LOCK (dbin);
|
||||
GST_LOG_OBJECT (dbin, "clearing shutdown flag");
|
||||
dbin->shutdown = FALSE;
|
||||
|
@ -4446,10 +4448,12 @@ gst_decode_bin_change_state (GstElement * element, GstStateChange transition)
|
|||
switch (transition) {
|
||||
case GST_STATE_CHANGE_PAUSED_TO_READY:
|
||||
do_async_done (dbin);
|
||||
EXPOSE_LOCK (dbin);
|
||||
if (dbin->decode_chain) {
|
||||
gst_decode_chain_free (dbin->decode_chain);
|
||||
dbin->decode_chain = NULL;
|
||||
}
|
||||
EXPOSE_UNLOCK (dbin);
|
||||
break;
|
||||
case GST_STATE_CHANGE_READY_TO_NULL:
|
||||
default:
|
||||
|
|
Loading…
Reference in a new issue