From dbef9fb84b0deceb7ee576958a2d785a1bf15681 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Sat, 28 Dec 2024 11:00:24 +0100 Subject: [PATCH v2 2/4] Add another pg_noreturn The previous change revealed a compiler warning about possibly uninitialized variables, which this fixes. Discussion: https://www.postgresql.org/message-id/flat/pxr5b3z7jmkpenssra5zroxi7qzzp6eswuggokw64axmdixpnk@zbwxuq7gbbcw --- src/common/parse_manifest.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/common/parse_manifest.c b/src/common/parse_manifest.c index 05858578207..71973af199b 100644 --- a/src/common/parse_manifest.c +++ b/src/common/parse_manifest.c @@ -114,8 +114,8 @@ static void json_manifest_finalize_wal_range(JsonManifestParseState *parse); static void verify_manifest_checksum(JsonManifestParseState *parse, const char *buffer, size_t size, pg_cryptohash_ctx *incr_ctx); -static void json_manifest_parse_failure(JsonManifestParseContext *context, - char *msg); +pg_noreturn static void json_manifest_parse_failure(JsonManifestParseContext *context, + char *msg); static int hexdecode_char(char c); static bool hexdecode_string(uint8 *result, char *input, int nbytes); @@ -889,6 +889,7 @@ static void json_manifest_parse_failure(JsonManifestParseContext *context, char *msg) { context->error_cb(context, "could not parse backup manifest: %s", msg); + pg_unreachable(); } /* -- 2.48.1