Skip site navigation (1) Skip section navigation (2)

Re: testing cvs HEAD - HS/SR - missing file

From: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc: Erik Rijkers <er(at)xs4all(dot)nl>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: testing cvs HEAD - HS/SR - missing file
Date: 2010-01-27 10:05:53
Message-ID: 4B601001.8020508@enterprisedb.com (view raw or flat)
Thread:
Lists: pgsql-hackers
Fujii Masao wrote:
> *** a/src/backend/replication/walsender.c
> --- b/src/backend/replication/walsender.c
> ***************
> *** 661,666 **** XLogSend(StringInfo outMsg)
> --- 661,673 ----
>   
>   		sentPtr = endptr;
>   
> + 		if (sentPtr.xrecoff >= XLogFileSize)
> + 		{
> + 			/* crossing a logid boundary */
> + 			sentPtr.xlogid += 1;
> + 			sentPtr.xrecoff = 0;
> + 		}
> + 
>   		/*
>   		 * Read the log directly into the output buffer to prevent
>   		 * extra memcpy calls.
> 

Before that, endptr is advanced using XLByteAdvance() macro, which does
handle xlogid boundaries. Is XLByteAdvance() broken?

-- 
  Heikki Linnakangas
  EnterpriseDB   http://www.enterprisedb.com

In response to

Responses

pgsql-hackers by date

Next:From: Tim BunceDate: 2010-01-27 10:07:44
Subject: Re: Add on_perl_init and proper destruction to plperl [PATCH]
Previous:From: Magnus HaganderDate: 2010-01-27 10:01:32
Subject: Re: Patch: psql \whoami option

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group