pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter@eisentraut.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix compiler warnings around _CRT_glob
Date: Wed, 01 Oct 2025 15:19:15 +0000
Message-ID: <E1v3ybq-000x5F-2O@gemulon.postgresql.org> (raw)

Fix compiler warnings around _CRT_glob

Newer compilers warned about

    extern int _CRT_glob = 0;

which is indeed a mysterious C construction, as it combines "extern"
and an initialization.  It turns out that according to the C standard,
the "extern" is ignored here, so we can remove it to resolve the
warnings.  But then we also need to add a real extern
declaration (without initializer) to satisfy
-Wmissing-variable-declarations.

(Note that this code is only active on MinGW.)

Discussion: https://www.postgresql.org/message-id/1053279b-da01-4eb4-b7a3-da6b5d8f73d1%40eisentraut.org

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/3e908fb54ff8fa857180bc212ca79c7bd95dcc2c

Modified Files
--------------
src/common/exec.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)



Message-ID: <E1v3ybq-000x5F-2O@gemulon.postgresql.org>
Permalink:  ../E1v3ybq-000x5F-2O@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1v3ybq-000x5F-2O@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: peter@eisentraut.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Fix compiler warnings around _CRT_glob
  In-Reply-To: <E1v3ybq-000x5F-2O@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox