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 1txRr5-009UoE-5q for pgsql-bugs@arkaria.postgresql.org; Wed, 26 Mar 2025 14:35:43 +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 1txRr3-004GIy-NR for pgsql-bugs@arkaria.postgresql.org; Wed, 26 Mar 2025 14:35:41 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1txRr3-004GIp-Dv for pgsql-bugs@lists.postgresql.org; Wed, 26 Mar 2025 14:35:41 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1txRr0-001KJD-38 for pgsql-bugs@lists.postgresql.org; Wed, 26 Mar 2025 14:35:41 +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 52QEZapP1449239; Wed, 26 Mar 2025 10:35:36 -0400 From: Tom Lane To: dan-eli@mail.ru cc: pgsql-bugs@lists.postgresql.org Subject: Re: BUG #18869: /src/backend/optimizer/plan/createplan.c clause can be null if user isn't root In-reply-to: <18869-0bacaab42e8d02eb@postgresql.org> References: <18869-0bacaab42e8d02eb@postgresql.org> Comments: In-reply-to PG Bug reporting form message dated "Wed, 26 Mar 2025 10:20:05 -0000" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1449237.1742999736.1@sss.pgh.pa.us> Date: Wed, 26 Mar 2025 10:35:36 -0400 Message-ID: <1449238.1742999736@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk PG Bug reporting form writes: > If root is NULL, pointer clause can also be NULL and then dereferenced at > createplan.c:5104 at if (IsA(clause, OpExpr)). I guess there should be a > check for NULL. root would never be null here, and neither would the clause. In general, we are not terribly interested in "bug reports" generated by unsupported static analysis. regards, tom lane