mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-07-04 13:45:52 +00:00
multiqueue: Clean up after the streaming thread has stopped
https://bugzilla.gnome.org/show_bug.cgi?id=705835
This commit is contained in:
parent
d7c3be226c
commit
b40599f6db
|
@ -1474,7 +1474,19 @@ gst_multi_queue_sink_activate_mode (GstPad * pad, GstObject * parent,
|
||||||
sq->last_query = FALSE;
|
sq->last_query = FALSE;
|
||||||
g_cond_signal (&sq->query_handled);
|
g_cond_signal (&sq->query_handled);
|
||||||
gst_data_queue_set_flushing (sq->queue, TRUE);
|
gst_data_queue_set_flushing (sq->queue, TRUE);
|
||||||
|
|
||||||
|
/* Wait until streaming thread has finished */
|
||||||
|
if (mq)
|
||||||
|
GST_MULTI_QUEUE_MUTEX_UNLOCK (mq);
|
||||||
|
GST_PAD_STREAM_LOCK (pad);
|
||||||
|
if (mq)
|
||||||
|
GST_MULTI_QUEUE_MUTEX_LOCK (mq);
|
||||||
gst_data_queue_flush (sq->queue);
|
gst_data_queue_flush (sq->queue);
|
||||||
|
if (mq)
|
||||||
|
GST_MULTI_QUEUE_MUTEX_UNLOCK (mq);
|
||||||
|
GST_PAD_STREAM_UNLOCK (pad);
|
||||||
|
if (mq)
|
||||||
|
GST_MULTI_QUEUE_MUTEX_LOCK (mq);
|
||||||
}
|
}
|
||||||
res = TRUE;
|
res = TRUE;
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue