1 /* vi: set sw=4 ts=4: */
3 * vfork test for uClibc
5 * Copyright (C) 2000-2006 by Erik Andersen <andersen@uclibc.org>
6 * Written by Erik Andersen <andersen@uclibc.org>
8 * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
15 #include <sys/types.h>
29 if ((pid = vfork()) == 0) {
30 printf("Hi. I'm the child process...\n");
31 execvp(argv[0], argv);
35 printf("Hello. I'm the parent process.\n");
38 if (wpid > 0 && wpid != pid) {
45 printf("Child process exited.\nGoodbye.\n");