public inbox for [email protected]
help / color / mirror / Atom feedFrom: David Rowley <[email protected]>
To: Masahiko Sawada <[email protected]>
Cc: [email protected]
Subject: Re: pgsql: pg_logicalinspect: Fix possible crash when passing a directory p
Date: Wed, 12 Mar 2025 15:08:22 +1300
Message-ID: <CAApHDvqrhFfnetbcwgGkJ=z63T8HfQ_OyP=vX8BYiXyxFKt67w@mail.gmail.com> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
On Wed, 12 Mar 2025 at 05:57, Masahiko Sawada <[email protected]> wrote:
> contrib/pg_logicalinspect/pg_logicalinspect.c | 55 ++++++++++++---
This introduces a new compiler warning for compilers that don't know
the ereport(ERROR) does not return.
The attached is enough to fix it.
David
Attachments:
[application/octet-stream] fix_parse_snapshot_filename_warning.patch (457B, 2-fix_parse_snapshot_filename_warning.patch)
download | inline diff:
diff --git a/contrib/pg_logicalinspect/pg_logicalinspect.c b/contrib/pg_logicalinspect/pg_logicalinspect.c
index 3b64d8ad880..13f9bda9459 100644
--- a/contrib/pg_logicalinspect/pg_logicalinspect.c
+++ b/contrib/pg_logicalinspect/pg_logicalinspect.c
@@ -85,6 +85,8 @@ parse_snapshot_filename(const char *filename)
parse_error:
ereport(ERROR,
errmsg("invalid snapshot file name \"%s\"", filename));
+
+ return 0; /* keep compiler quiet */
}
/*
view thread (16+ messages) latest in thread
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: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: pgsql: pg_logicalinspect: Fix possible crash when passing a directory p
In-Reply-To: <CAApHDvqrhFfnetbcwgGkJ=z63T8HfQ_OyP=vX8BYiXyxFKt67w@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox