diff options
author | Sebastian Dröge <sebastian@centricular.com> | 2016-08-18 15:28:33 +0300 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2016-08-18 15:28:33 +0300 |
commit | 0d06f4bc7c6af1935cc595b93ef3f7abf1b6f4b0 (patch) | |
tree | 50dd43a1d05a2ef9a5ced750b3c6a0690dac97f0 | |
parent | e786f737ae83fb009ffcf599c3e0dce6ecab67a7 (diff) |
mplex: Don't start task (yet/again) on pad release if we're in READY or NULL
Fixes spurious segfault in unit test, where the task was started again during
shutdown when all pads were removed... and was then still running while the
element was finalized.
-rw-r--r-- | ext/mplex/gstmplex.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/mplex/gstmplex.cc b/ext/mplex/gstmplex.cc index 408948559..7f7b4ecae 100644 --- a/ext/mplex/gstmplex.cc +++ b/ext/mplex/gstmplex.cc @@ -676,7 +676,8 @@ gst_mplex_release_pad (GstElement * element, GstPad * pad) g_free (padname); /* may now be up to us to get things going */ - gst_mplex_start_task (mplex); + if (GST_STATE (element) > GST_STATE_READY) + gst_mplex_start_task (mplex); GST_MPLEX_MUTEX_UNLOCK (mplex); } } |