On Mon, Jan 24, 2011 at 4:47 PM, Magnus Hagander <[email protected]> wrote:
> On Mon, Jan 24, 2011 at 08:45, Fujii Masao <[email protected]> wrote:
>> On Fri, Jan 21, 2011 at 12:28 AM, Tom Lane <[email protected]> wrote:
>>> Magnus Hagander <[email protected]> writes:
>>>>> - Why not initialize logid and logseg like so?:
>>>>>
>>>>>        int logid = startptr.xlogid;
>>>>>        int logseg = startptr.xrecoff / XLogSegSize;
>>>>>
>>>>>  Then use those in your elog?  Seems cleaner to me.
>>>
>>>> Hmm. Yes. Agreed.
>>>
>>> Marginal complaint here: int is the wrong type, I'm pretty sure.
>>
>> And, we should use XLByteToPrevSeg here instead of just =, I think.
>
> Not XLByteToSeg?

Checking... yeah, you are right. We should use XLByteToSeg since
the REDO starting WAL record doesn't exist in the previous WAL
segment when the REDO starting location is a boundary byte.

Regards,

-- 
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

-- 
Sent via pgsql-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to