As part of the WAL-format changing patch I've been working on, I changed the signature of the rm_desc function from:

void (*rm_desc) (StringInfo buf, uint8 xl_info, char *rec);
void (*rm_desc) (StringInfo buf, XLogRecord *record);

The WAL-format patch needed that because it added more functions/macros for working with XLogRecords, also used by rm_desc routines, but it seems like a sensible change anyway. IMHO it was always a bit strange that rm_desc was passed the info field and record payload separately.

So I propose to do that change as a separate commit. Per attached. This has no functional changes, it's just refactoring.

Any objections?

- Heikki
commit aa645133fa92dcf4c89749f5121bf4c6631d298c
Author: Heikki Linnakangas <heikki.linnakan...@iki.fi>
Date:   Fri Jun 13 14:20:39 2014 +0300

    Change the signature of rm_desc so that it's passed XLogRecord.

diff --git a/contrib/pg_xlogdump/pg_xlogdump.c b/contrib/pg_xlogdump/pg_xlogdump.c
index 824b8c3..c555786 100644
--- a/contrib/pg_xlogdump/pg_xlogdump.c
+++ b/contrib/pg_xlogdump/pg_xlogdump.c
@@ -351,7 +351,7 @@ XLogDumpDisplayRecord(XLogDumpConfig *config, XLogRecPtr ReadRecPtr, XLogRecord
 		   !!(XLR_BKP_BLOCK(3) & record->xl_info));
 
 	/* the desc routine will printf the description directly to stdout */
-	desc->rm_desc(NULL, record->xl_info, XLogRecGetData(record));
+	desc->rm_desc(NULL, record);
 
 	putchar('\n');
 
diff --git a/contrib/pg_xlogdump/rmgrdesc.h b/contrib/pg_xlogdump/rmgrdesc.h
index edf8257..d964118 100644
--- a/contrib/pg_xlogdump/rmgrdesc.h
+++ b/contrib/pg_xlogdump/rmgrdesc.h
@@ -13,7 +13,7 @@
 typedef struct RmgrDescData
 {
 	const char *rm_name;
-	void		(*rm_desc) (StringInfo buf, uint8 xl_info, char *rec);
+	void		(*rm_desc) (StringInfo buf, XLogRecord *record);
 } RmgrDescData;
 
 extern const RmgrDescData RmgrDescTable[];
diff --git a/src/backend/access/rmgrdesc/clogdesc.c b/src/backend/access/rmgrdesc/clogdesc.c
index 25a8522..e82baa8 100644
--- a/src/backend/access/rmgrdesc/clogdesc.c
+++ b/src/backend/access/rmgrdesc/clogdesc.c
@@ -18,9 +18,10 @@
 
 
 void
-clog_desc(StringInfo buf, uint8 xl_info, char *rec)
+clog_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	if (info == CLOG_ZEROPAGE)
 	{
diff --git a/src/backend/access/rmgrdesc/dbasedesc.c b/src/backend/access/rmgrdesc/dbasedesc.c
index 1ea02e7..0230716 100644
--- a/src/backend/access/rmgrdesc/dbasedesc.c
+++ b/src/backend/access/rmgrdesc/dbasedesc.c
@@ -19,9 +19,10 @@
 
 
 void
-dbase_desc(StringInfo buf, uint8 xl_info, char *rec)
+dbase_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	if (info == XLOG_DBASE_CREATE)
 	{
diff --git a/src/backend/access/rmgrdesc/gindesc.c b/src/backend/access/rmgrdesc/gindesc.c
index cd1edff..12d68d7 100644
--- a/src/backend/access/rmgrdesc/gindesc.c
+++ b/src/backend/access/rmgrdesc/gindesc.c
@@ -77,9 +77,10 @@ desc_recompress_leaf(StringInfo buf, ginxlogRecompressDataLeaf *insertData)
 }
 
 void
-gin_desc(StringInfo buf, uint8 xl_info, char *rec)
+gin_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	switch (info)
 	{
@@ -121,7 +122,7 @@ gin_desc(StringInfo buf, uint8 xl_info, char *rec)
 					ginxlogRecompressDataLeaf *insertData =
 					(ginxlogRecompressDataLeaf *) payload;
 
-					if (xl_info & XLR_BKP_BLOCK(0))
+					if (record->xl_info & XLR_BKP_BLOCK(0))
 						appendStringInfo(buf, " (full page image)");
 					else
 						desc_recompress_leaf(buf, insertData);
@@ -159,7 +160,7 @@ gin_desc(StringInfo buf, uint8 xl_info, char *rec)
 
 				appendStringInfoString(buf, "Vacuum data leaf page, ");
 				desc_node(buf, xlrec->node, xlrec->blkno);
-				if (xl_info & XLR_BKP_BLOCK(0))
+				if (record->xl_info & XLR_BKP_BLOCK(0))
 					appendStringInfo(buf, " (full page image)");
 				else
 					desc_recompress_leaf(buf, &xlrec->data);
diff --git a/src/backend/access/rmgrdesc/gistdesc.c b/src/backend/access/rmgrdesc/gistdesc.c
index b7f8766..cdac496 100644
--- a/src/backend/access/rmgrdesc/gistdesc.c
+++ b/src/backend/access/rmgrdesc/gistdesc.c
@@ -42,9 +42,10 @@ out_gistxlogPageSplit(StringInfo buf, gistxlogPageSplit *xlrec)
 }
 
 void
-gist_desc(StringInfo buf, uint8 xl_info, char *rec)
+gist_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	switch (info)
 	{
diff --git a/src/backend/access/rmgrdesc/hashdesc.c b/src/backend/access/rmgrdesc/hashdesc.c
index 23be856..86a0376 100644
--- a/src/backend/access/rmgrdesc/hashdesc.c
+++ b/src/backend/access/rmgrdesc/hashdesc.c
@@ -17,6 +17,6 @@
 #include "access/hash.h"
 
 void
-hash_desc(StringInfo buf, uint8 xl_info, char *rec)
+hash_desc(StringInfo buf, XLogRecord *record)
 {
 }
diff --git a/src/backend/access/rmgrdesc/heapdesc.c b/src/backend/access/rmgrdesc/heapdesc.c
index c8a6166..7df18fa 100644
--- a/src/backend/access/rmgrdesc/heapdesc.c
+++ b/src/backend/access/rmgrdesc/heapdesc.c
@@ -41,16 +41,17 @@ out_infobits(StringInfo buf, uint8 infobits)
 }
 
 void
-heap_desc(StringInfo buf, uint8 xl_info, char *rec)
+heap_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	info &= XLOG_HEAP_OPMASK;
 	if (info == XLOG_HEAP_INSERT)
 	{
 		xl_heap_insert *xlrec = (xl_heap_insert *) rec;
 
-		if (xl_info & XLOG_HEAP_INIT_PAGE)
+		if (record->xl_info & XLOG_HEAP_INIT_PAGE)
 			appendStringInfoString(buf, "insert(init): ");
 		else
 			appendStringInfoString(buf, "insert: ");
@@ -69,7 +70,7 @@ heap_desc(StringInfo buf, uint8 xl_info, char *rec)
 	{
 		xl_heap_update *xlrec = (xl_heap_update *) rec;
 
-		if (xl_info & XLOG_HEAP_INIT_PAGE)
+		if (record->xl_info & XLOG_HEAP_INIT_PAGE)
 			appendStringInfoString(buf, "update(init): ");
 		else
 			appendStringInfoString(buf, "update: ");
@@ -85,7 +86,7 @@ heap_desc(StringInfo buf, uint8 xl_info, char *rec)
 	{
 		xl_heap_update *xlrec = (xl_heap_update *) rec;
 
-		if (xl_info & XLOG_HEAP_INIT_PAGE)		/* can this case happen? */
+		if (record->xl_info & XLOG_HEAP_INIT_PAGE)	/* can this case happen? */
 			appendStringInfoString(buf, "hot_update(init): ");
 		else
 			appendStringInfoString(buf, "hot_update: ");
@@ -126,9 +127,10 @@ heap_desc(StringInfo buf, uint8 xl_info, char *rec)
 		appendStringInfoString(buf, "UNKNOWN");
 }
 void
-heap2_desc(StringInfo buf, uint8 xl_info, char *rec)
+heap2_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	info &= XLOG_HEAP_OPMASK;
 	if (info == XLOG_HEAP2_CLEAN)
@@ -172,7 +174,7 @@ heap2_desc(StringInfo buf, uint8 xl_info, char *rec)
 	{
 		xl_heap_multi_insert *xlrec = (xl_heap_multi_insert *) rec;
 
-		if (xl_info & XLOG_HEAP_INIT_PAGE)
+		if (record->xl_info & XLOG_HEAP_INIT_PAGE)
 			appendStringInfoString(buf, "multi-insert (init): ");
 		else
 			appendStringInfoString(buf, "multi-insert: ");
diff --git a/src/backend/access/rmgrdesc/mxactdesc.c b/src/backend/access/rmgrdesc/mxactdesc.c
index daf9b41..50d9b55 100644
--- a/src/backend/access/rmgrdesc/mxactdesc.c
+++ b/src/backend/access/rmgrdesc/mxactdesc.c
@@ -47,9 +47,10 @@ out_member(StringInfo buf, MultiXactMember *member)
 }
 
 void
-multixact_desc(StringInfo buf, uint8 xl_info, char *rec)
+multixact_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	if (info == XLOG_MULTIXACT_ZERO_OFF_PAGE)
 	{
diff --git a/src/backend/access/rmgrdesc/nbtdesc.c b/src/backend/access/rmgrdesc/nbtdesc.c
index a3c746f..bf3389c 100644
--- a/src/backend/access/rmgrdesc/nbtdesc.c
+++ b/src/backend/access/rmgrdesc/nbtdesc.c
@@ -26,9 +26,10 @@ out_target(StringInfo buf, xl_btreetid *target)
 }
 
 void
-btree_desc(StringInfo buf, uint8 xl_info, char *rec)
+btree_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	switch (info)
 	{
diff --git a/src/backend/access/rmgrdesc/relmapdesc.c b/src/backend/access/rmgrdesc/relmapdesc.c
index 8409016..06fd4b3 100644
--- a/src/backend/access/rmgrdesc/relmapdesc.c
+++ b/src/backend/access/rmgrdesc/relmapdesc.c
@@ -17,9 +17,10 @@
 #include "utils/relmapper.h"
 
 void
-relmap_desc(StringInfo buf, uint8 xl_info, char *rec)
+relmap_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	if (info == XLOG_RELMAP_UPDATE)
 	{
diff --git a/src/backend/access/rmgrdesc/seqdesc.c b/src/backend/access/rmgrdesc/seqdesc.c
index 726fb2a..42eb9b9 100644
--- a/src/backend/access/rmgrdesc/seqdesc.c
+++ b/src/backend/access/rmgrdesc/seqdesc.c
@@ -18,9 +18,10 @@
 
 
 void
-seq_desc(StringInfo buf, uint8 xl_info, char *rec)
+seq_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 	xl_seq_rec *xlrec = (xl_seq_rec *) rec;
 
 	if (info == XLOG_SEQ_LOG)
diff --git a/src/backend/access/rmgrdesc/smgrdesc.c b/src/backend/access/rmgrdesc/smgrdesc.c
index aa72d4c..c76c815 100644
--- a/src/backend/access/rmgrdesc/smgrdesc.c
+++ b/src/backend/access/rmgrdesc/smgrdesc.c
@@ -19,9 +19,10 @@
 
 
 void
-smgr_desc(StringInfo buf, uint8 xl_info, char *rec)
+smgr_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	if (info == XLOG_SMGR_CREATE)
 	{
diff --git a/src/backend/access/rmgrdesc/spgdesc.c b/src/backend/access/rmgrdesc/spgdesc.c
index 9c41097..ed369b2 100644
--- a/src/backend/access/rmgrdesc/spgdesc.c
+++ b/src/backend/access/rmgrdesc/spgdesc.c
@@ -24,9 +24,10 @@ out_target(StringInfo buf, RelFileNode node)
 }
 
 void
-spg_desc(StringInfo buf, uint8 xl_info, char *rec)
+spg_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	switch (info)
 	{
diff --git a/src/backend/access/rmgrdesc/standbydesc.c b/src/backend/access/rmgrdesc/standbydesc.c
index 80cc7dc..a127d38 100644
--- a/src/backend/access/rmgrdesc/standbydesc.c
+++ b/src/backend/access/rmgrdesc/standbydesc.c
@@ -37,9 +37,10 @@ standby_desc_running_xacts(StringInfo buf, xl_running_xacts *xlrec)
 }
 
 void
-standby_desc(StringInfo buf, uint8 xl_info, char *rec)
+standby_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	if (info == XLOG_STANDBY_LOCK)
 	{
diff --git a/src/backend/access/rmgrdesc/tblspcdesc.c b/src/backend/access/rmgrdesc/tblspcdesc.c
index a0ccd0e..30b1f06 100644
--- a/src/backend/access/rmgrdesc/tblspcdesc.c
+++ b/src/backend/access/rmgrdesc/tblspcdesc.c
@@ -18,9 +18,10 @@
 
 
 void
-tblspc_desc(StringInfo buf, uint8 xl_info, char *rec)
+tblspc_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	if (info == XLOG_TBLSPC_CREATE)
 	{
diff --git a/src/backend/access/rmgrdesc/xactdesc.c b/src/backend/access/rmgrdesc/xactdesc.c
index 7c43d4c..994931e 100644
--- a/src/backend/access/rmgrdesc/xactdesc.c
+++ b/src/backend/access/rmgrdesc/xactdesc.c
@@ -137,9 +137,10 @@ xact_desc_assignment(StringInfo buf, xl_xact_assignment *xlrec)
 }
 
 void
-xact_desc(StringInfo buf, uint8 xl_info, char *rec)
+xact_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	if (info == XLOG_XACT_COMMIT_COMPACT)
 	{
diff --git a/src/backend/access/rmgrdesc/xlogdesc.c b/src/backend/access/rmgrdesc/xlogdesc.c
index e3d7b66..2224da1 100644
--- a/src/backend/access/rmgrdesc/xlogdesc.c
+++ b/src/backend/access/rmgrdesc/xlogdesc.c
@@ -32,9 +32,10 @@ const struct config_enum_entry wal_level_options[] = {
 };
 
 void
-xlog_desc(StringInfo buf, uint8 xl_info, char *rec)
+xlog_desc(StringInfo buf, XLogRecord *record)
 {
-	uint8		info = xl_info & ~XLR_INFO_MASK;
+	char	   *rec = XLogRecGetData(record);
+	uint8		info = record->xl_info & ~XLR_INFO_MASK;
 
 	if (info == XLOG_CHECKPOINT_SHUTDOWN ||
 		info == XLOG_CHECKPOINT_ONLINE)
diff --git a/src/backend/access/transam/xlog.c b/src/backend/access/transam/xlog.c
index 3f92482..029c68e 100644
--- a/src/backend/access/transam/xlog.c
+++ b/src/backend/access/transam/xlog.c
@@ -1276,11 +1276,12 @@ begin:;
 			rdt_lastnormal->next = NULL;
 
 			initStringInfo(&recordbuf);
+			appendBinaryStringInfo(&recordbuf, (char *) &rechdr, sizeof(XLogRecord));
 			for (; rdata != NULL; rdata = rdata->next)
 				appendBinaryStringInfo(&recordbuf, rdata->data, rdata->len);
 
 			appendStringInfoString(&buf, " - ");
-			RmgrTable[rechdr->xl_rmid].rm_desc(&buf, rechdr->xl_info, recordbuf.data);
+			RmgrTable[rechdr->xl_rmid].rm_desc(&buf, (XLogRecord *) recordbuf.data);
 			pfree(recordbuf.data);
 		}
 		elog(LOG, "%s", buf.data);
@@ -6627,9 +6628,7 @@ StartupXLOG(void)
 							 (uint32) (EndRecPtr >> 32), (uint32) EndRecPtr);
 					xlog_outrec(&buf, record);
 					appendStringInfoString(&buf, " - ");
-					RmgrTable[record->xl_rmid].rm_desc(&buf,
-													   record->xl_info,
-													 XLogRecGetData(record));
+					RmgrTable[record->xl_rmid].rm_desc(&buf, record);
 					elog(LOG, "%s", buf.data);
 					pfree(buf.data);
 				}
@@ -10453,9 +10452,7 @@ rm_redo_error_callback(void *arg)
 	StringInfoData buf;
 
 	initStringInfo(&buf);
-	RmgrTable[record->xl_rmid].rm_desc(&buf,
-									   record->xl_info,
-									   XLogRecGetData(record));
+	RmgrTable[record->xl_rmid].rm_desc(&buf, record);
 
 	/* don't bother emitting empty description */
 	if (buf.len > 0)
diff --git a/src/include/access/clog.h b/src/include/access/clog.h
index 66a6d17..be9b867 100644
--- a/src/include/access/clog.h
+++ b/src/include/access/clog.h
@@ -48,6 +48,6 @@ extern void TruncateCLOG(TransactionId oldestXact);
 #define CLOG_TRUNCATE		0x10
 
 extern void clog_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void clog_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void clog_desc(StringInfo buf, XLogRecord *record);
 
 #endif   /* CLOG_H */
diff --git a/src/include/access/gin.h b/src/include/access/gin.h
index 4cda0ec..a0b288d 100644
--- a/src/include/access/gin.h
+++ b/src/include/access/gin.h
@@ -73,7 +73,7 @@ extern void ginUpdateStats(Relation index, const GinStatsData *stats);
 
 /* ginxlog.c */
 extern void gin_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void gin_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void gin_desc(StringInfo buf, XLogRecord *record);
 extern void gin_xlog_startup(void);
 extern void gin_xlog_cleanup(void);
 
diff --git a/src/include/access/gist_private.h b/src/include/access/gist_private.h
index 089c679..03e9903 100644
--- a/src/include/access/gist_private.h
+++ b/src/include/access/gist_private.h
@@ -451,7 +451,7 @@ extern SplitedPageLayout *gistSplit(Relation r, Page page, IndexTuple *itup,
 
 /* gistxlog.c */
 extern void gist_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void gist_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void gist_desc(StringInfo buf, XLogRecord *record);
 extern void gist_xlog_startup(void);
 extern void gist_xlog_cleanup(void);
 
diff --git a/src/include/access/hash.h b/src/include/access/hash.h
index d89bcea..2062801 100644
--- a/src/include/access/hash.h
+++ b/src/include/access/hash.h
@@ -355,6 +355,6 @@ extern OffsetNumber _hash_binsearch_last(Page page, uint32 hash_value);
 
 /* hash.c */
 extern void hash_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void hash_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void hash_desc(StringInfo buf, XLogRecord *record);
 
 #endif   /* HASH_H */
diff --git a/src/include/access/heapam_xlog.h b/src/include/access/heapam_xlog.h
index cfdd1ff..05beb00 100644
--- a/src/include/access/heapam_xlog.h
+++ b/src/include/access/heapam_xlog.h
@@ -367,10 +367,10 @@ typedef struct xl_heap_rewrite_mapping
 extern void HeapTupleHeaderAdvanceLatestRemovedXid(HeapTupleHeader tuple,
 									   TransactionId *latestRemovedXid);
 
-extern void heap_redo(XLogRecPtr lsn, XLogRecord *rptr);
-extern void heap_desc(StringInfo buf, uint8 xl_info, char *rec);
-extern void heap2_redo(XLogRecPtr lsn, XLogRecord *rptr);
-extern void heap2_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void heap_redo(XLogRecPtr lsn, XLogRecord *record);
+extern void heap_desc(StringInfo buf, XLogRecord *record);
+extern void heap2_redo(XLogRecPtr lsn, XLogRecord *record);
+extern void heap2_desc(StringInfo buf, XLogRecord *record);
 extern void heap_xlog_logical_rewrite(XLogRecPtr lsn, XLogRecord *r);
 
 extern XLogRecPtr log_heap_cleanup_info(RelFileNode rnode,
diff --git a/src/include/access/multixact.h b/src/include/access/multixact.h
index 80c7074..448ec10 100644
--- a/src/include/access/multixact.h
+++ b/src/include/access/multixact.h
@@ -134,7 +134,7 @@ extern void multixact_twophase_postabort(TransactionId xid, uint16 info,
 							 void *recdata, uint32 len);
 
 extern void multixact_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void multixact_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void multixact_desc(StringInfo buf, XLogRecord *record);
 extern char *mxid_to_string(MultiXactId multi, int nmembers,
 			   MultiXactMember *members);
 
diff --git a/src/include/access/nbtree.h b/src/include/access/nbtree.h
index f281759..ed6f697 100644
--- a/src/include/access/nbtree.h
+++ b/src/include/access/nbtree.h
@@ -724,6 +724,6 @@ extern void _bt_leafbuild(BTSpool *btspool, BTSpool *spool2);
  * prototypes for functions in nbtxlog.c
  */
 extern void btree_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void btree_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void btree_desc(StringInfo buf, XLogRecord *record);
 
 #endif   /* NBTREE_H */
diff --git a/src/include/access/spgist.h b/src/include/access/spgist.h
index 9187b4a..7f8655c 100644
--- a/src/include/access/spgist.h
+++ b/src/include/access/spgist.h
@@ -197,7 +197,7 @@ extern Datum spgvacuumcleanup(PG_FUNCTION_ARGS);
 
 /* spgxlog.c */
 extern void spg_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void spg_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void spg_desc(StringInfo buf, XLogRecord *record);
 extern void spg_xlog_startup(void);
 extern void spg_xlog_cleanup(void);
 
diff --git a/src/include/access/xact.h b/src/include/access/xact.h
index 634f5b2..10ee943 100644
--- a/src/include/access/xact.h
+++ b/src/include/access/xact.h
@@ -256,6 +256,6 @@ extern void UnregisterSubXactCallback(SubXactCallback callback, void *arg);
 extern int	xactGetCommittedChildren(TransactionId **ptr);
 
 extern void xact_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void xact_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void xact_desc(StringInfo buf, XLogRecord *record);
 
 #endif   /* XACT_H */
diff --git a/src/include/access/xlog.h b/src/include/access/xlog.h
index 1eaa5c1..85f9cb7 100644
--- a/src/include/access/xlog.h
+++ b/src/include/access/xlog.h
@@ -298,7 +298,7 @@ extern Buffer RestoreBackupBlock(XLogRecPtr lsn, XLogRecord *record,
 				   bool get_cleanup_lock, bool keep_buffer);
 
 extern void xlog_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void xlog_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void xlog_desc(StringInfo buf, XLogRecord *record);
 
 extern void issue_xlog_fsync(int fd, XLogSegNo segno);
 
diff --git a/src/include/access/xlog_internal.h b/src/include/access/xlog_internal.h
index 3a692cd..8c8de38 100644
--- a/src/include/access/xlog_internal.h
+++ b/src/include/access/xlog_internal.h
@@ -245,7 +245,7 @@ typedef struct RmgrData
 {
 	const char *rm_name;
 	void		(*rm_redo) (XLogRecPtr lsn, struct XLogRecord *rptr);
-	void		(*rm_desc) (StringInfo buf, uint8 xl_info, char *rec);
+	void		(*rm_desc) (StringInfo buf, struct XLogRecord *rptr);
 	void		(*rm_startup) (void);
 	void		(*rm_cleanup) (void);
 } RmgrData;
diff --git a/src/include/catalog/storage_xlog.h b/src/include/catalog/storage_xlog.h
index 43bf277..7081c99 100644
--- a/src/include/catalog/storage_xlog.h
+++ b/src/include/catalog/storage_xlog.h
@@ -44,6 +44,6 @@ typedef struct xl_smgr_truncate
 extern void log_smgrcreate(RelFileNode *rnode, ForkNumber forkNum);
 
 extern void smgr_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void smgr_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void smgr_desc(StringInfo buf, XLogRecord *record);
 
 #endif   /* STORAGE_XLOG_H */
diff --git a/src/include/commands/dbcommands.h b/src/include/commands/dbcommands.h
index fa10295..c2380dc 100644
--- a/src/include/commands/dbcommands.h
+++ b/src/include/commands/dbcommands.h
@@ -63,7 +63,7 @@ extern Oid	get_database_oid(const char *dbname, bool missingok);
 extern char *get_database_name(Oid dbid);
 
 extern void dbase_redo(XLogRecPtr lsn, XLogRecord *rptr);
-extern void dbase_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void dbase_desc(StringInfo buf, XLogRecord *rptr);
 
 extern void check_encoding_locale_matches(int encoding, const char *collate, const char *ctype);
 
diff --git a/src/include/commands/sequence.h b/src/include/commands/sequence.h
index 7d8a370..8819c00 100644
--- a/src/include/commands/sequence.h
+++ b/src/include/commands/sequence.h
@@ -77,6 +77,6 @@ extern void ResetSequence(Oid seq_relid);
 extern void ResetSequenceCaches(void);
 
 extern void seq_redo(XLogRecPtr lsn, XLogRecord *rptr);
-extern void seq_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void seq_desc(StringInfo buf, XLogRecord *rptr);
 
 #endif   /* SEQUENCE_H */
diff --git a/src/include/commands/tablespace.h b/src/include/commands/tablespace.h
index 1603f67..073cb0d 100644
--- a/src/include/commands/tablespace.h
+++ b/src/include/commands/tablespace.h
@@ -57,6 +57,6 @@ extern char *get_tablespace_name(Oid spc_oid);
 extern bool directory_is_empty(const char *path);
 
 extern void tblspc_redo(XLogRecPtr lsn, XLogRecord *rptr);
-extern void tblspc_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void tblspc_desc(StringInfo buf, XLogRecord *rptr);
 
 #endif   /* TABLESPACE_H */
diff --git a/src/include/pg_config_manual.h b/src/include/pg_config_manual.h
index d1f99fb..0f4402f 100644
--- a/src/include/pg_config_manual.h
+++ b/src/include/pg_config_manual.h
@@ -281,7 +281,7 @@
  * Enable debugging print statements for WAL-related operations; see
  * also the wal_debug GUC var.
  */
-/* #define WAL_DEBUG */
+#define WAL_DEBUG
 
 /*
  * Enable tracing of resource consumption during sort operations;
diff --git a/src/include/storage/standby.h b/src/include/storage/standby.h
index 89ab704..da22fd3 100644
--- a/src/include/storage/standby.h
+++ b/src/include/storage/standby.h
@@ -82,7 +82,7 @@ typedef struct xl_running_xacts
 
 /* Recovery handlers for the Standby Rmgr (RM_STANDBY_ID) */
 extern void standby_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void standby_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void standby_desc(StringInfo buf, XLogRecord *record);
 
 /*
  * Declarations for GetRunningTransactionData(). Similar to Snapshots, but
diff --git a/src/include/utils/relmapper.h b/src/include/utils/relmapper.h
index 2452c94..76bcf18 100644
--- a/src/include/utils/relmapper.h
+++ b/src/include/utils/relmapper.h
@@ -59,6 +59,6 @@ extern void RelationMapInitializePhase2(void);
 extern void RelationMapInitializePhase3(void);
 
 extern void relmap_redo(XLogRecPtr lsn, XLogRecord *record);
-extern void relmap_desc(StringInfo buf, uint8 xl_info, char *rec);
+extern void relmap_desc(StringInfo buf, XLogRecord *record);
 
 #endif   /* RELMAPPER_H */
-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to