aboutsummaryrefslogtreecommitdiffstats
path: root/tests/vfork.c
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--tests/vfork.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/vfork.c b/tests/vfork.c
new file mode 100644
index 0000000..d8c61ba
--- /dev/null
+++ b/tests/vfork.c
@@ -0,0 +1,14 @@
+#include <unistd.h>
+
+int
+main(void)
+{
+ switch (vfork()) {
+ case -1:
+ return -1;
+ case 0:
+ _exit(2);
+ default:
+ return 1;
+ }
+}