summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndres Freund <andres@anarazel.de>2019-10-29 22:46:40 -0700
committerAndres Freund <andres@anarazel.de>2019-10-29 22:54:36 -0700
commitbc4f56c181aede01715f3a44232ce3e373fc8cfb (patch)
tree763fbb4fb985ba7c8d086af9e21e2e2100e41251
parent95f2efd5041b95cb92e3940e79cbbb65c4c4b09e (diff)
pg_waldump: Fix --bkp-details to not issue spurious newlines for FPWs.
The additional newline seems to have accidentally been introduced in 2c03216d831, in 9.5. The newline is only issued when an FPW is present for the block reference. While there could be an argument that removing the newlines in the back branches could cause a problem for somebody parsing the pg_waldump output, the likelihood of that seems small enough. It seems at least equally likely that the randomness of when newlines are issued causes problems. Author: Andres Freund Discussion: https://postgr.es/m/20191029233341.4gnyau7e5v2lh5sc@alap3.anarazel.de Backpatch: 9.5, like 2c03216d831.
-rw-r--r--src/bin/pg_xlogdump/pg_xlogdump.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bin/pg_xlogdump/pg_xlogdump.c b/src/bin/pg_xlogdump/pg_xlogdump.c
index c950048c2b6..4ef52062619 100644
--- a/src/bin/pg_xlogdump/pg_xlogdump.c
+++ b/src/bin/pg_xlogdump/pg_xlogdump.c
@@ -509,7 +509,7 @@ XLogDumpDisplayRecord(XLogDumpConfig *config, XLogReaderState *record)
if (record->blocks[block_id].bimg_info &
BKPIMAGE_IS_COMPRESSED)
{
- printf(" (FPW); hole: offset: %u, length: %u, compression saved: %u\n",
+ printf(" (FPW); hole: offset: %u, length: %u, compression saved: %u",
record->blocks[block_id].hole_offset,
record->blocks[block_id].hole_length,
BLCKSZ -
@@ -518,7 +518,7 @@ XLogDumpDisplayRecord(XLogDumpConfig *config, XLogReaderState *record)
}
else
{
- printf(" (FPW); hole: offset: %u, length: %u\n",
+ printf(" (FPW); hole: offset: %u, length: %u",
record->blocks[block_id].hole_offset,
record->blocks[block_id].hole_length);
}