1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-03 15:22:11 +03:00

Add a message type header to the CopyData messages sent from primary

to standby in streaming replication. While we only have one message type
at the moment, adding a message type header makes this easier to extend.
This commit is contained in:
Heikki Linnakangas
2010-02-03 09:47:19 +00:00
parent 47c5b8f558
commit 808969d0e7
5 changed files with 117 additions and 35 deletions

View File

@@ -30,7 +30,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/replication/walsender.c,v 1.4 2010/01/27 16:41:09 heikki Exp $
* $PostgreSQL: pgsql/src/backend/replication/walsender.c,v 1.5 2010/02/03 09:47:19 heikki Exp $
*
*-------------------------------------------------------------------------
*/
@@ -659,6 +659,7 @@ XLogSend(StringInfo outMsg)
* have the same byte order. If they have different byte order, we
* don't reach here.
*/
pq_sendbyte(outMsg, 'w');
pq_sendbytes(outMsg, (char *) &startptr, sizeof(startptr));
if (endptr.xlogid != startptr.xlogid)