OSDN Git Service

use vfork instead of fork so test works on non-mmu
authorMike Frysinger <vapier@gentoo.org>
Tue, 21 Feb 2006 23:33:23 +0000 (23:33 -0000)
committerMike Frysinger <vapier@gentoo.org>
Tue, 21 Feb 2006 23:33:23 +0000 (23:33 -0000)
test/malloc/tst-mallocfork.c

index f90ce94..5bb1d76 100644 (file)
@@ -11,7 +11,7 @@
 static void
 sig_handler (int signum)
 {
-  pid_t child = fork ();
+  pid_t child = vfork ();
   if (child == 0)
     exit (0);
   TEMP_FAILURE_RETRY (waitpid (child, NULL, 0));
@@ -34,7 +34,7 @@ do_test (void)
     }
 
   /* Create a child that sends the signal to be caught.  */
-  pid_t child = fork ();
+  pid_t child = vfork ();
   if (child == 0)
     {
       if (kill (parent, SIGALRM) == -1)