]> granicus.if.org Git - gc/commit
Allow gctest and thread_leak_test with zero NTHREADS
authorIvan Maidanski <ivmai@mail.ru>
Wed, 9 Aug 2017 21:47:18 +0000 (00:47 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Wed, 9 Aug 2017 21:47:18 +0000 (00:47 +0300)
commit347c1f0d0b2be5c811e7449ae2afa1b1e2d42fcc
treed909ffdf361a20f968b6fbe4721faace5cd9a8a1
parente0611fadaa5efe21a31b69133b455160004865e1
Allow gctest and thread_leak_test with zero NTHREADS

* tests/test.c [GC_PTHREADS || GC_WIN32_THREADS] (reverse_test_inner):
Do not call fork_a_thread() if NTHREADS is 0.
* tests/test.c (MAX_FINALIZED): Increase to be correct for the case of
NTHREADS is 0.
* tests/test.c [GC_PTHREADS] (main): Do not declare and do not use th,
i local variables if NTHREADS is 0.
* tests/thread_leak_test.c (NTHREADS): Do not define if already defined.
* tests/thread_leak_test.c (main):  Do not declare and do not use i,
code, t, thread_id local variables if NTHREADS is 0.
tests/test.c
tests/thread_leak_test.c