From 3f493b04639b0a98c847fa91ef0a065505b4b798 Mon Sep 17 00:00:00 2001 From: cpickett Date: Thu, 1 Jan 2009 01:23:31 +0000 Subject: [PATCH] * try to detect CK_FORK problem on non-POSIX right after getenv() call git-svn-id: svn+ssh://svn.code.sf.net/p/check/code/trunk@518 64e312b2-a51f-0410-8e61-82d0ca0eb02a --- src/check_run.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/check_run.c b/src/check_run.c index 0e37178..c02c30b 100644 --- a/src/check_run.c +++ b/src/check_run.c @@ -522,8 +522,14 @@ enum fork_status srunner_fork_status (SRunner *sr) return CK_FORK; if (strcmp (env,"no") == 0) return CK_NOFORK; - else + else { +#ifdef _POSIX_VERSION return CK_FORK; +#else /* _POSIX_VERSION */ + eprintf("This version does not support fork", __FILE__, __LINE__); + return CK_NOFORK; +#endif /* _POSIX_VERSION */ + } } else return sr->fstat; } -- 2.40.0