Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1ZPfV8-0002AM-Gk for pgsql-hackers@arkaria.postgresql.org; Wed, 12 Aug 2015 23:32:06 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1ZPfV8-00045g-2X for pgsql-hackers@arkaria.postgresql.org; Wed, 12 Aug 2015 23:32:06 +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.84) (envelope-from ) id 1ZPfV6-00041n-AY for pgsql-hackers@postgresql.org; Wed, 12 Aug 2015 23:32:04 +0000 Received: from mail.anarazel.de ([217.115.131.40]) by makus.postgresql.org with esmtp (Exim 4.84) (envelope-from ) id 1ZPfV3-0006Fl-LB for pgsql-hackers@postgresql.org; Wed, 12 Aug 2015 23:32:03 +0000 Received: by mail.anarazel.de (Postfix, from userid 108) id 47F3A860001; Thu, 13 Aug 2015 01:31:59 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on mail X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=AWL,BAYES_00,NO_RELAYS autolearn=ham version=3.2.5 Received: from andres.at.anarazel.de.authenticated.anarazel.de by mail.anarazel.de (Postfix) with ESMTPSA id E0449860001 for ; Thu, 13 Aug 2015 01:31:56 +0200 (CEST) Received: by anarazel.de (Postfix, from userid 1000) id 6BA8D100485; Thu, 13 Aug 2015 01:31:56 +0200 (CEST) Date: Thu, 13 Aug 2015 01:31:56 +0200 From: Andres Freund To: Alvaro Herrera Cc: pgsql-hackers@postgresql.org Subject: Re: [COMMITTERS] pgsql: Close some holes in BRIN page assignment Message-ID: <20150812233156.GF21836@awork2.anarazel.de> References: <20150812190808.GM3040@postgresql.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20150812190808.GM3040@postgresql.org> X-Pg-Spam-Score: -4.2 (----) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org On 2015-08-12 16:08:08 -0300, Alvaro Herrera wrote: > Alvaro Herrera wrote: > > Close some holes in BRIN page assignment > > buildfarm evidently didn't like this one :-( clang seems to see a (the?) problem: /home/andres/src/postgresql/src/backend/access/brin/brin_pageops.c:357:6: warning: variable 'extended' is used uninitialized whenever 'if' condition is false [-Wsometimes-uninitialized] if (!BufferIsValid(*buffer)) ^~~~~~~~~~~~~~~~~~~~~~~ /home/andres/src/postgresql/src/backend/access/brin/brin_pageops.c:371:6: note: uninitialized use occurs here if (extended) ^~~~~~~~ /home/andres/src/postgresql/src/backend/access/brin/brin_pageops.c:357:2: note: remove the 'if' if its condition is always true if (!BufferIsValid(*buffer)) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /home/andres/src/postgresql/src/backend/access/brin/brin_pageops.c:330:16: note: initialize the variable 'extended' to silence this warning bool extended; Looks to me like it's right. That also explains why it's failing on a fairly random selection of platforms and compilers... Andres -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers