Re: pg_xlogdump fails to handle WAL file with multi-page XLP_FIRST_IS_CONTRECORD data - Mailing list pgsql-hackers

From Fujii Masao
Subject Re: pg_xlogdump fails to handle WAL file with multi-page XLP_FIRST_IS_CONTRECORD data
Date
Msg-id CAHGQGwGRhjYKZJ3BWf5Z3r82K4B2A5dpHPTxPTOsw-1dTm1SzQ@mail.gmail.com
Whole thread Raw
In response to Re: pg_xlogdump fails to handle WAL file with multi-page XLP_FIRST_IS_CONTRECORD data  (Pavan Deolasee <pavan.deolasee@gmail.com>)
Responses Re: pg_xlogdump fails to handle WAL file with multi-page XLP_FIRST_IS_CONTRECORD data  (Fujii Masao <masao.fujii@gmail.com>)
List pgsql-hackers
On Wed, Mar 23, 2016 at 7:04 PM, Pavan Deolasee
<pavan.deolasee@gmail.com> wrote:
>
>
> On Wed, Mar 23, 2016 at 1:13 PM, Michael Paquier <michael.paquier@gmail.com>
> wrote:
>>
>>
>> +       /*
>> +        * Compute targetRecOff. It should typically be greater than short
>> +        * page-header since a valid record can't , but can also be zero
>> when
>> +        * caller has supplied a page-aligned address or when we are
>> skipping
>> +        * multi-page continuation record. It doesn't matter though
>> because
>> +        * ReadPageInternal() will read at least short page-header worth
>> of
>> +        * data
>> +        */
>> This needs some polishing, there is an unfinished sentence here.
>>
>> +       targetRecOff = tmpRecPtr % XLOG_BLCKSZ;
>> targetRecOff, pageHeaderSize and targetPagePtr could be declared
>> inside directly the new while loop.
>
>
> Thanks Michael for reviewing the patch. I've fixed these issues and new
> version is attached.

The patch looks good to me. Barring any objections,
I'll push this and back-patch to 9.3 where pg_xlogdump was added.

Regards,

-- 
Fujii Masao



pgsql-hackers by date:

Previous
From: Stephen Frost
Date:
Subject: Re: patch proposal
Next
From: Jürgen Purtz
Date:
Subject: Unsupported feature F867: WITH TIES