harness: fix the race in blocking push mode
authorMikhail Fludkov <misha@pexip.com>
Tue, 4 Aug 2015 15:09:35 +0000 (17:09 +0200)
committerTim-Philipp Müller <tim@centricular.com>
Fri, 12 Feb 2016 12:32:22 +0000 (12:32 +0000)
commit06ae41e0b211402d3032762ad4788ae3eef06a97
tree9e7a058ddc417aa47ba2f07be2c7ac60b5d5ea3d
parent2450af1034e4e8fbe0a30413c66e4464656a6ee2
harness: fix the race in blocking push mode

Depending on when gst_harness_pull was called - before the buffer reached
gst_harness_chain or after we can get different behaviors of the test
with enabled blocking push mode. The fix makes the behavior always the
same. In pull function we get the buffer first, thus making sure
gst_harness_chain waits for the signal, and emitting the signal after.

https://bugzilla.gnome.org/show_bug.cgi?id=761931
libs/gst/check/gstharness.c