diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2013-02-08 22:53:14 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2013-02-08 22:53:14 +0000 |
commit | 3219f837f162088ad89b2102d1fcf71b293c14fc (patch) | |
tree | e683adb1fe0d36ce9fa9f6219951a8fa2cc369c8 /apps/examples/ostest/vfork.c | |
parent | 08650208d65dad8629ef44064f443dfbc2420f38 (diff) | |
download | px4-nuttx-3219f837f162088ad89b2102d1fcf71b293c14fc.tar.gz px4-nuttx-3219f837f162088ad89b2102d1fcf71b293c14fc.tar.bz2 px4-nuttx-3219f837f162088ad89b2102d1fcf71b293c14fc.zip |
Fix some problems with the vfork() test on the STM32F3Discovery
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5628 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'apps/examples/ostest/vfork.c')
-rw-r--r-- | apps/examples/ostest/vfork.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/apps/examples/ostest/vfork.c b/apps/examples/ostest/vfork.c index 4e1b8c892..fd99d1aea 100644 --- a/apps/examples/ostest/vfork.c +++ b/apps/examples/ostest/vfork.c @@ -47,6 +47,9 @@ #include "ostest.h" +#if defined(CONFIG_ARCH_HAVE_VFORK) && defined(CONFIG_SCHED_WAITPID) && \ + !defined(CONFIG_DISABLE_SIGNALS) + /**************************************************************************** * Pre-processor Definitions ****************************************************************************/ @@ -55,9 +58,7 @@ * Private Data ****************************************************************************/ -#if defined(CONFIG_ARCH_HAVE_VFORK) && !defined(CONFIG_DISABLE_SIGNALS) static volatile bool g_vforkchild; -#endif /**************************************************************************** * Public Functions @@ -65,7 +66,6 @@ static volatile bool g_vforkchild; int vfork_test(void) { -#if defined(CONFIG_ARCH_HAVE_VFORK) && !defined(CONFIG_DISABLE_SIGNALS) pid_t pid; g_vforkchild = false; @@ -97,7 +97,8 @@ int vfork_test(void) return -1; } } -#endif return 0; } + +#endif /* CONFIG_ARCH_HAVE_VFORK && CONFIG_SCHED_WAITPID && !CONFIG_DISABLE_SIGNALS */ |