From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Kxhd3-0006Co-M4 for qemu-devel@nongnu.org; Wed, 05 Nov 2008 07:36:57 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Kxhd2-0006CZ-0t for qemu-devel@nongnu.org; Wed, 05 Nov 2008 07:36:57 -0500 Received: from [199.232.76.173] (port=54878 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Kxhd1-0006CW-RM for qemu-devel@nongnu.org; Wed, 05 Nov 2008 07:36:55 -0500 Received: from mail2.shareable.org ([80.68.89.115]:45656) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Kxhd1-0006vV-Sn for qemu-devel@nongnu.org; Wed, 05 Nov 2008 07:36:56 -0500 Date: Wed, 5 Nov 2008 12:36:50 +0000 From: Jamie Lokier Subject: Re: [Qemu-devel] Re: [PATCH] Fix alarm_timer race with select Message-ID: <20081105123650.GE13630@shareable.org> References: <490FFF23.5020704@web.de> <49105704.9070708@codemonkey.ws> <49105BE7.6030505@codemonkey.ws> <49108333.6080807@web.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <49108333.6080807@web.de> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Jan Kiszka Jan Kiszka wrote: > + if (pipe(fds) || fcntl(fds[0], F_SETFL, O_NONBLOCK) > + || fcntl(fds[1], F_SETFL, O_NONBLOCK)) { Is this a portable way to set O_NONBLOCK on all host platforms? I'm under the impression you need to ues F_GETFL first, in case other flags are important to the functioning of the file descriptor. -- Jamie