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 1ucFAC-00AhF2-A2 for pgsql-committers@arkaria.postgresql.org; Thu, 17 Jul 2025 03:20: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 1ucFA9-00G0ZX-PI for pgsql-committers@arkaria.postgresql.org; Thu, 17 Jul 2025 03:20: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 1ucFA9-00G0ZO-Gg for pgsql-committers@lists.postgresql.org; Thu, 17 Jul 2025 03:20: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.96) (envelope-from ) id 1ucFA8-007grl-0y; Thu, 17 Jul 2025 03:20:01 +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 56H3Ju241330027; Wed, 16 Jul 2025 23:19:56 -0400 From: Tom Lane To: David Rowley cc: Peter Eisentraut , Masahiko Sawada , pgsql-committers@lists.postgresql.org Subject: Re: pgsql: pg_logicalinspect: Fix possible crash when passing a directory p In-reply-to: References: <6c00a8b2-0c40-44f0-b603-f6ae28b7694a@eisentraut.org> <1244428.1752677780@sss.pgh.pa.us> Comments: In-reply-to David Rowley message dated "Thu, 17 Jul 2025 12:52:07 +1200" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1330025.1752722396.1@sss.pgh.pa.us> Date: Wed, 16 Jul 2025 23:19:56 -0400 Message-ID: <1330026.1752722396@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk David Rowley writes: > On Thu, 17 Jul 2025 at 02:56, Tom Lane wrote: >> Looking again at the code for ereport_domain(), I wondered if >> something like this would help MSVC see through it: > I tried this and it unfortunately doesn't fix the issue. I didn't have huge hopes for that, but thanks for checking. > I spent a bit more time searching for a solution and did find > something that works well enough for this case in [1]. Unfortunately, > it only works with C11. See attached .c file and output below. Hmph. I doubt we are ready to require C11 everywhere, but maybe we could require it in MSVC builds? Which MSVC versions would that eliminate? regards, tom lane