Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cw9CN-0001qS-37 for pgsql-committers@arkaria.postgresql.org; Thu, 06 Apr 2017 15:19:47 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1cw9CM-0001zP-MO for pgsql-committers@arkaria.postgresql.org; Thu, 06 Apr 2017 15:19:46 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1cw9CM-0001zG-EY for pgsql-committers@postgresql.org; Thu, 06 Apr 2017 15:19:46 +0000 Received: from out1-smtp.messagingengine.com ([66.111.4.25]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1cw9CJ-00013G-1o for pgsql-committers@postgresql.org; Thu, 06 Apr 2017 15:19:45 +0000 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id 97A4420C18; Thu, 6 Apr 2017 11:19:41 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute7.internal (MEProxy); Thu, 06 Apr 2017 11:19:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s= fm1; bh=2iM+58UO9HX1FUWolTd+UPXUFN7SReFcT3CKfQDr3eA=; b=Zg02cwwa deiUHiW69IAXASTMQQh+SIfL+MFSZR3zJ6JKUzYm0Txi0necfSaXUSEbV1sBlF/U J7P0t6RaDZFw1iHr05q00xsfAvhxCsF/jcnzEUOdBEyKeJSkvRqxJ5WI5KFdLDxD f20x9tAZxpdivTdWxAaUZbbVCxCnmaIsva6XzdMZ/K9Yb+a2AmG5pcMkOzD3PfqM UAAxCilLy0EMtaiJ1sgjmncpWqblt1eP043IMtfV6E7mD2J9zzYB5a2sFsK6FKTC wybSGHvEQQT/h5+DJcJRMKwyyXLLntZoBIsDeCeS1UWPfkv8VpC3Hwu2ymgxMmAc BNHk2U3Q4JyAFA== X-ME-Sender: X-Sasl-enc: 6u33KbG8VyeUjxAHEgv2FHMjEHjGxFrC2pHD10sfx++h 1491491981 Received: from april.local (c-73-13-66-39.hsd1.pa.comcast.net [73.13.66.39]) by mail.messagingengine.com (Postfix) with ESMTPA id 5827A244AE; Thu, 6 Apr 2017 11:19:41 -0400 (EDT) Subject: Re: pgsql: Identity columns To: Tom Lane References: <22227.1491488685@sss.pgh.pa.us> Cc: pgsql-committers@postgresql.org From: Peter Eisentraut Organization: 2ndQuadrant Message-ID: <8ea7e815-956c-33fd-a2fa-f88861e32086@2ndquadrant.com> Date: Thu, 6 Apr 2017 11:19:41 -0400 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <22227.1491488685@sss.pgh.pa.us> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-committers Precedence: bulk Sender: pgsql-committers-owner@postgresql.org On 4/6/17 10:24, Tom Lane wrote: > This commit is causing a compiler warning for me: > > tablecmds.c: In function 'ATExecSetIdentity': > tablecmds.c:5936: warning: 'address.objectSubId' may be used uninitialized in this function > tablecmds.c:5936: warning: 'address.objectId' may be used uninitialized in this function > > I'm not sure why it's not complaining about all three fields, because > AFAICS, the function returns a totally undefined ObjectAddress when > generatedEl is not set. Yeah, that was an oversight. It's depressing that not more compilers warn about an obvious case like this. I have pushed a fix. > What is the intention there? (If the function > were adequately documented, maybe I could divine that for myself, but > heaven help the reader who would like to know what this function is > supposed to do.) Added some comments, too. -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers