From: Michael Paquier <michael@paquier.xyz>
To: Ayush Tiwari <ayushtiwari.slg01@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Subject: Re: [PATCH] Fix WAL block image length diagnostic
Date: Fri, 4 Sep 2026 17:15:55 +0900
Message-ID: <app-OoQAe2TDBorI@paquier.xyz> (raw)
In-Reply-To: <CAJTYsWVz9ymE7aMt2ZiQvs1bxNvhjfTf+XaJEsdFw7MT5dvtYQ@mail.gmail.com>
References: <CAJTYsWVz9ymE7aMt2ZiQvs1bxNvhjfTf+XaJEsdFw7MT5dvtYQ@mail.gmail.com>
On Fri, Sep 04, 2026 at 01:31:03PM +0530, Ayush Tiwari wrote:
> While reading DecodeXLogRecord(), I noticed that one error path checks
> blk->bimg_len but prints blk->data_len. The latter is the length of
> resource manager data and can be unrelated to the malformed block image.
> [I'm assuming intention was always to print blk->bimg_len]
Ah, yeah, it looks like you are right on this one. Showing data_len
makes no sense.
> The attached patch reports bimg_len instead. The typo was introduced
> with WAL compression in 57aa5b2bb11 and is present in all supported
> branches, so I think it should be backpatched through 14?
Yes. Will check later..
--
Michael
Attachments:
signature.asc (application/pgp-signature, 832B) download
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-hackers@postgresql.org
Cc: michael@paquier.xyz, ayushtiwari.slg01@gmail.com
Subject: Re: [PATCH] Fix WAL block image length diagnostic
In-Reply-To: <app-OoQAe2TDBorI@paquier.xyz>
References: <CAJTYsWVz9ymE7aMt2ZiQvs1bxNvhjfTf+XaJEsdFw7MT5dvtYQ@mail.gmail.com> <app-OoQAe2TDBorI@paquier.xyz>
* 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