From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1N13Wh-0005cN-DK for qemu-devel@nongnu.org; Thu, 22 Oct 2009 15:40:47 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1N13Wc-0005PA-8v for qemu-devel@nongnu.org; Thu, 22 Oct 2009 15:40:46 -0400 Received: from [199.232.76.173] (port=53619 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N13Wc-0005Oq-3c for qemu-devel@nongnu.org; Thu, 22 Oct 2009 15:40:42 -0400 Received: from mx1.redhat.com ([209.132.183.28]:41990) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1N13Wb-0006IW-Bf for qemu-devel@nongnu.org; Thu, 22 Oct 2009 15:40:41 -0400 Message-Id: <20091022193912.063620036@redhat.com> Date: Thu, 22 Oct 2009 17:38:17 -0200 From: Marcelo Tosatti References: <20091022193816.147000901@redhat.com> Content-Disposition: inline; filename=block-sigchld Subject: [Qemu-devel] [patch 1/2] qemu: block SIGCHLD in vcpu thread(s) List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: glommer@redhat.com, Marcelo Tosatti , aliguori@us.ibm.com Otherwise a vcpu thread can run the sigchild handler causing waitpid() from iothread to fail. Signed-off-by: Marcelo Tosatti Index: qemu/vl.c =================================================================== --- qemu.orig/vl.c +++ qemu/vl.c @@ -3722,6 +3722,7 @@ static void block_io_signals(void) sigaddset(&set, SIGUSR2); sigaddset(&set, SIGIO); sigaddset(&set, SIGALRM); + sigaddset(&set, SIGCHLD); pthread_sigmask(SIG_BLOCK, &set, NULL); sigemptyset(&set);