Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rFRPk-009t0j-3W for pgsql-bugs@arkaria.postgresql.org; Tue, 19 Dec 2023 04:09:04 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rFRPi-00EpFp-IE for pgsql-bugs@arkaria.postgresql.org; Tue, 19 Dec 2023 04:09:02 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rFRPi-00EpFh-9f for pgsql-bugs@lists.postgresql.org; Tue, 19 Dec 2023 04:09:02 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rFRPf-00B6gc-Gs for pgsql-bugs@lists.postgresql.org; Tue, 19 Dec 2023 04:09:00 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 3BJ48vEG4150262; Mon, 18 Dec 2023 23:08:57 -0500 From: Tom Lane To: Richard Guo cc: Junwang Zhao , rekgrpth@gmail.com, pgsql-bugs@lists.postgresql.org Subject: Re: BUG #18247: Integer overflow leads to negative width In-reply-to: References: <18247-11ac477f02954422@postgresql.org> <2781181.1702565025@sss.pgh.pa.us> <2993260.1702654983@sss.pgh.pa.us> <4099430.1702933230@sss.pgh.pa.us> Comments: In-reply-to Richard Guo message dated "Tue, 19 Dec 2023 11:32:29 +0800" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <4150260.1702958937.1@sss.pgh.pa.us> Date: Mon, 18 Dec 2023 23:08:57 -0500 Message-ID: <4150261.1702958937@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Richard Guo writes: > I agree with all the comments made. I have also examined other places > where the width field is assigned, and I think we've covered all cases. > So the v3 patch is in good shape to me. Thanks for looking! Do you have an opinion about the int64-vs-double question? regards, tom lane