From e5f24dee2d115d6a7f51cd4cae0b086c5be5c0de Mon Sep 17 00:00:00 2001 From: Garett D'Amore Date: Sun, 1 Jan 2017 20:14:36 -0800 Subject: Valgrind test fixes (leaks due to unreaped threads.) --- tests/platform.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'tests/platform.c') diff --git a/tests/platform.c b/tests/platform.c index aa14ffeb..d408959c 100644 --- a/tests/platform.c +++ b/tests/platform.c @@ -141,10 +141,14 @@ TestMain("Platform Operations", { Convey("It ran", { nni_usleep(50000); // for context switch So(val == 1); + nni_thr_fini(&thr); }) Convey("We can reap it", { nni_thr_fini(&thr); }) + Reset({ + nni_thr_fini(&thr); + }) }) }) Convey("Condition variables work", { @@ -198,5 +202,9 @@ TestMain("Platform Operations", { nni_mtx_unlock(&arg.mx); nni_thr_fini(&thr); }) + + Reset({ + nni_thr_fini(&thr); + }) }) -}) \ No newline at end of file +}) -- cgit v1.2.3-70-g09d2