validate: Do not check pulling thread when thread is paused

With decodebin3 we have cases where a task has been started in
the `typefind` element but the demuxer is the one pulling (from
its own thread)

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-devtools/-/merge_requests/183>
This commit is contained in:
Thibault Saunier 2020-03-19 18:25:28 -03:00
parent 75d30ae2d3
commit 640469ce0c

View file

@ -2488,7 +2488,7 @@ gst_validate_pad_monitor_get_range_func (GstPad * pad, GstObject * parent,
if (peer) {
GST_OBJECT_LOCK (peer);
task = GST_PAD_TASK (peer);
if (task) {
if (task && GST_TASK_STATE (task) == GST_TASK_STARTED) {
GST_OBJECT_LOCK (task);
/* Only doing pointer comparison, no need to hold a ref */
thread = task->thread;