From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KYe6C-000895-DP for qemu-devel@nongnu.org; Thu, 28 Aug 2008 05:47:28 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KYe69-00087e-SV for qemu-devel@nongnu.org; Thu, 28 Aug 2008 05:47:26 -0400 Received: from [199.232.76.173] (port=45959 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KYe69-00087Q-G2 for qemu-devel@nongnu.org; Thu, 28 Aug 2008 05:47:25 -0400 Received: from smtp.eu.citrix.com ([62.200.22.115]:14392) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KYe68-0000Vk-VL for qemu-devel@nongnu.org; Thu, 28 Aug 2008 05:47:25 -0400 Received: from samy by implementation.famille.thibault.fr with local (Exim 4.69) (envelope-from ) id 1KYe67-0001cN-FJ for qemu-devel@nongnu.org; Thu, 28 Aug 2008 11:47:23 +0200 Date: Thu, 28 Aug 2008 10:47:23 +0100 From: Samuel Thibault Subject: Re: [Qemu-devel][PATCH] block level testing/execersing utility Message-ID: <20080828094723.GF4523@implementation.uk.xensource.com> References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: 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 Shahar Frank, le Thu 28 Aug 2008 02:27:13 -0700, a écrit : > can do also multiple threading. > > + arg->offset = random() * arg->blocksize; Take care: random() uses a central mutex for safety. Use rand_r or rand48_r instead. Samuel