Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f2KXl-0005H5-N4 for pgsql-committers@arkaria.postgresql.org; Sat, 31 Mar 2018 17:43:57 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f2KXk-0002yB-7R for pgsql-committers@arkaria.postgresql.org; Sat, 31 Mar 2018 17:43:56 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f2KXj-0002y2-VN for pgsql-committers@lists.postgresql.org; Sat, 31 Mar 2018 17:43:56 +0000 Received: from [77.158.173.139] (helo=cascavel.ensmp.fr) by makus.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f2KXg-0002Vt-JY for pgsql-committers@lists.postgresql.org; Sat, 31 Mar 2018 17:43:54 +0000 Received: from cri.ensmp.fr (161.200.219.88.rev.sfr.net [88.219.200.161]) (authenticated bits=0) by cascavel.ensmp.fr (8.15.2/8.15.2/JMMC-22/Oct/2013) with ESMTPSA id w2VHhcMN029076 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Sat, 31 Mar 2018 19:43:39 +0200 Date: Sat, 31 Mar 2018 19:43:38 +0200 (CEST) From: Fabien COELHO X-X-Sender: fabien@lancre To: Tom Lane cc: Teodor Sigaev , pgsql-committers@lists.postgresql.org Subject: Re: pgsql: Set random seed for pgbench. In-Reply-To: <10686.1522514072@sss.pgh.pa.us> Message-ID: References: <32390.1522464534@sss.pgh.pa.us> <10686.1522514072@sss.pgh.pa.us> User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed X-Miltered: at cascavel.ensmp.fr with ID 5ABFC8CA.000 by Joe's j-chkmail (http : // j-chkmail dot ensmp dot fr)! X-j-chkmail-Auth: USER-ID coelho X-j-chkmail-Enveloppe: 5ABFC8CA.000 from 161.200.219.88.rev.sfr.net/161.200.219.88.rev.sfr.net/88.219.200.161/cri.ensmp.fr/ X-Host-Lookup-Failed: Reverse DNS lookup failed for 77.158.173.139 (deferred) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk >> I assumed that pg_strong_random is always available, > > ... which is wrong. Every other call of it is wrapped in > #ifdef HAVE_STRONG_RANDOM, and so must this one be. Indeed, I clearly misunderstood its usage pattern. I looked at its source ("src/port/pg_strong_random.c") where the function is always defined and is documented as returning false if it does not find a strong random source, so I though that checking for this was enough. But indeed its compilation fails if no source is provided. Thanks for the fix. -- Fabien.