GNOME Bugzilla – Bug 625547
imagefreeze unit test fails occasionally
Last modified: 2010-09-04 13:11:30 UTC
When running the test case for imagefreeze it fails. Funny thing is that it sometimes passes, but mostly it fails. I'm using gstreamer 0.10.30 gst-plugins-base 0.10.30 gst-plugins-good 0.10.24 Running suite(s): imagefreeze 60%: Checks: 5, Failures: 2, Errors: 0 /home/patrickr/work/p3301_1/libs/gst-plugins-good/gst-plugins-good/tests/check/elements/imagefreeze.c:164:F:linear:test_imagefreeze_25_1_0ms_400ms:0: 'GST_BUFFER_TIMESTAMP (buffer)' (0) is not equal to '*n_buffers * 40 * GST_MSECOND' (80000000) /home/patrickr/work/p3301_1/libs/gst-plugins-good/gst-plugins-good/tests/check/elements/imagefreeze.c:228:F:linear:test_imagefreeze_25_1_200ms_400ms:0: 'GST_BUFFER_TIMESTAMP (buffer)' (0) is not equal to '200 * GST_MSECOND + *n_buffers * 40 * GST_MSECOND' (200000000) Running suite(s): imagefreeze 60%: Checks: 5, Failures: 2, Errors: 0 /home/patrickr/work/p3301_1/libs/gst-plugins-good/gst-plugins-good/tests/check/elements/imagefreeze.c:228:F:linear:test_imagefreeze_25_1_200ms_400ms:0: 'GST_BUFFER_TIMESTAMP (buffer)' (0) is not equal to '200 * GST_MSECOND + *n_buffers * 40 * GST_MSECOND' (200000000) /home/patrickr/work/p3301_1/libs/gst-plugins-good/gst-plugins-good/tests/check/elements/imagefreeze.c:293:F:linear:test_imagefreeze_25_1_400ms_0ms:0: 'GST_BUFFER_TIMESTAMP (buffer)' (0) is not equal to '400 * GST_MSECOND - (*n_buffers + 1) * 40 * GST_MSECOND' (360000000) make: *** [elements/imagefreeze.check] Error 2
Created attachment 167886 [details] debug log for test_imagefreeze_25_1_0ms_400ms failure I can reproduce this with git / latest pre-release: tpm@zingle:~/gst/git/gst-plugins-good/tests/check$ make elements/imagefreeze.valgrind-forever make[1]: Entering directory `/home/tpm/gst/git/gst-plugins-good/tests/check' Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 100%: Checks: 5, Failures: 0, Errors: 0 Running suite(s): imagefreeze 80%: Checks: 5, Failures: 1, Errors: 0 elements/imagefreeze.c:164:F:linear:test_imagefreeze_25_1_0ms_400ms:0: 'GST_BUFFER_TIMESTAMP (buffer)' (0) is not equal to '*n_buffers * 40 * GST_MSECOND' (40000000) Attaching debug log (for failing test only).
I can reproduce this here too sometimes. But your debug log doesn't make much sense, this would mean that this is the second buffer and that it has a timestamp of 0. The debug log claims, that only a single buffer is pushed by imagefreeze for that test. Must be a bug somewhere in the test I think but I can't find anything obvious and I can't reproduce it when enabling debug output...
Ok, found two problems... will try to get them fixed ;)
Ok, fixed this locally with some other related bugs that appeared. I'll push all this after the release because the changes are not trivial. Only *this* bug here can be fixed by a small change in the testsuite but I got some other failures more often than this one while trying to reproduce it. And these failures need non-trivial changes to imagefreeze.
commit 5cd240952e9c9a6dfbbac854d5c1bef8d970ff1e Author: Sebastian Dröge <sebastian.droege@collabora.co.uk> Date: Fri Aug 20 10:35:15 2010 +0200 imagefreeze: Fix race conditions in the unit test If setting the pipeline to PLAYING before issuing the seek, buffers are already arriving at the sink before the seek is handled and will have the wrong timestamps and everything. Fixes bug #625547.