Skip to contentSkip to conversation

[5279] Band-aid vfork() emulation (Kirill Shutemov).

Qemu-devel Andrzej Zaborowski 1 participant 1 message Sep 21, 2008

lore
Share & tools
lore
#0 lore raw

Revision: 5279

          http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=5279
Author:   balrog
Date:     2008-09-21 02:39:45 +0000 (Sun, 21 Sep 2008)

Log Message:
-----------
Band-aid vfork() emulation (Kirill Shutemov).

Modified Paths:
--------------
trunk/linux-user/syscall.c

Modified: trunk/linux-user/syscall.c
===================================================================

linux-user/syscall.c +4 -0
@@ -2800,6 +2800,10 @@
     sigset_t sigmask;
 #endif
 
+    /* Emulate vfork() with fork() */
+    if (flags & CLONE_VFORK)
+        flags &= ~(CLONE_VFORK | CLONE_VM);
+
     if (flags & CLONE_VM) {
 #if defined(USE_NPTL)
         new_thread_info info;