diff options
author | Sebastian Dröge <slomo@circular-chaos.org> | 2008-12-16 12:37:15 +0000 |
---|---|---|
committer | Sebastian Dröge <slomo@circular-chaos.org> | 2008-12-16 12:37:15 +0000 |
commit | f6a5f4fa71040613c1c967288d86be5a3814a799 (patch) | |
tree | 5ad93712b4262aeb4391ccd6c4bd5bb6bb70526e /tests/check/elements/mxfdemux.c | |
parent | 5587f912104a8b4b7d3fbc71c9b7e39981235b43 (diff) | |
download | gst-plugins-bad-f6a5f4fa71040613c1c967288d86be5a3814a799.tar.gz gst-plugins-bad-f6a5f4fa71040613c1c967288d86be5a3814a799.tar.bz2 gst-plugins-bad-f6a5f4fa71040613c1c967288d86be5a3814a799.zip |
tests/check/elements/mxfdemux.*: Make sure the main loop is already running when handling the EOS event in pull mode....
Original commit message from CVS:
* tests/check/elements/mxfdemux.c: (_sink_event):
* tests/check/elements/mxfdemux.h:
Make sure the main loop is already running when handling the EOS
event in pull mode. This works around a race condition that can
happen if the element goes into PLAYING, handles everything and
sends EOS before the main loop is started.
Diffstat (limited to 'tests/check/elements/mxfdemux.c')
-rw-r--r-- | tests/check/elements/mxfdemux.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/check/elements/mxfdemux.c b/tests/check/elements/mxfdemux.c index 18db0ffc..65c151ed 100644 --- a/tests/check/elements/mxfdemux.c +++ b/tests/check/elements/mxfdemux.c @@ -82,6 +82,10 @@ static gboolean _sink_event (GstPad * pad, GstEvent * event) { if (GST_EVENT_TYPE (event) == GST_EVENT_EOS) { + if (loop) { + while (!g_main_loop_is_running (loop)); + } + have_eos = TRUE; if (loop) g_main_loop_quit (loop); |