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 1tx7HI-0036Cz-91 for pgsql-bugs@arkaria.postgresql.org; Tue, 25 Mar 2025 16:37:24 +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 1tx7HH-006iZD-0T for pgsql-bugs@arkaria.postgresql.org; Tue, 25 Mar 2025 16:37:23 +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 1tx7HG-006iYt-Oa for pgsql-bugs@lists.postgresql.org; Tue, 25 Mar 2025 16:37:22 +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.96) (envelope-from ) id 1tx7HF-0014j7-0T for pgsql-bugs@lists.postgresql.org; Tue, 25 Mar 2025 16:37:21 +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 52PGbFqZ1280898; Tue, 25 Mar 2025 12:37:15 -0400 From: Tom Lane To: Tender Wang cc: tharakan@gmail.com, pgsql-bugs@lists.postgresql.org, Heikki Linnakangas Subject: Re: BUG #18866: Running pg_freespace() on views triggers an Abort In-reply-to: References: <18866-d68926d0f1c72d44@postgresql.org> Comments: In-reply-to Tender Wang message dated "Tue, 25 Mar 2025 23:45:07 +0800" MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-ID: <1280896.1742920635.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Tue, 25 Mar 2025 12:37:15 -0400 Message-ID: <1280897.1742920635@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Tender Wang writes: > PG Bug reporting form =E4=BA=8E2025=E5=B9=B43=E6= =9C=8825=E6=97=A5=E5=91=A8=E4=BA=8C 22:42=E5=86=99=E9=81=93=EF=BC=9A >> Passing a view to pg_freespace() triggers an Abort on HEAD. > I think we can remove the Assert in smgropen(). > Any thoughts? That seems like a "solution" that will allow other bugs. pg_freespace should be fixed to verify RELKIND_HAS_STORAGE() before it tries to access said storage. regards, tom lane