check: use _exit() instead of exit() in fail_unless() so we exit immediately
authorTim-Philipp Müller <tim@centricular.com>
Fri, 2 May 2014 16:02:37 +0000 (17:02 +0100)
committerTim-Philipp Müller <tim@centricular.com>
Wed, 7 May 2014 09:44:34 +0000 (10:44 +0100)
commita10ca2ee137bf3446116a61f42d6a350705254fe
tree7d90887cdeb01aff3b3f405553f2c4b6099f2b12
parent4e1699e030e1fafff1192ee654f51e2eb8649a9c
check: use _exit() instead of exit() in fail_unless() so we exit immediately

exit() will call atexit handlers, which may try to
clean up things or wait for things to get cleaned up,
which we don't want or need. We just want to stop
and let the parent know about the failure as quickly
as possible in case fork() is used.

Fixes timeouts on assert failures in checks where
an exit handler waits for things to stop, but they
don't stop because they haven't been shut down,
and they haven't been shut down because there's no
simple way to do so on failures.

http://sourceforge.net/p/check/patches/50/
libs/gst/check/libcheck/check.c