Skip to content

Commit 4aba61b

Browse files
committed
Add some forgotten LSN_FORMAT_ARGS() in xlogreader.c
6f6f284 has introduced a specific macro to make printf()-ing of LSNs easier. This takes care of what looks like the remaining code paths that did not get the call. Author: Michael Paquier Reviewed-by: Kyotaro Horiguchi, Tom Lane Discussion: https://postgr.es/m/YIJS9x6K8ruizN7j@paquier.xyz
1 parent bb3ecc8 commit 4aba61b

File tree

1 file changed

+5
-10
lines changed

1 file changed

+5
-10
lines changed

src/backend/access/transam/xlogreader.c

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -754,8 +754,7 @@ XLogDecodeOneRecord(XLogReaderState *state, bool allow_oversized)
754754
targetRecOff == pageHeaderSize)
755755
{
756756
report_invalid_record(state, "contrecord is requested by %X/%X",
757-
(uint32) (state->DecodeRecPtr >> 32),
758-
(uint32) state->DecodeRecPtr);
757+
LSN_FORMAT_ARGS(state->DecodeRecPtr));
759758
goto err;
760759
}
761760

@@ -968,10 +967,8 @@ XLogDecodeOneRecord(XLogReaderState *state, bool allow_oversized)
968967
report_invalid_record(
969968
state,
970969
"there is no contrecord flag at %X/%X reading %X/%X",
971-
(uint32) (state->recordContRecPtr >> 32),
972-
(uint32) state->recordContRecPtr,
973-
(uint32) (state->DecodeRecPtr >> 32),
974-
(uint32) state->DecodeRecPtr);
970+
LSN_FORMAT_ARGS(state->recordContRecPtr),
971+
LSN_FORMAT_ARGS(state->DecodeRecPtr));
975972
goto err;
976973
}
977974

@@ -986,10 +983,8 @@ XLogDecodeOneRecord(XLogReaderState *state, bool allow_oversized)
986983
state,
987984
"invalid contrecord length %u at %X/%X reading %X/%X, expected %u",
988985
pageHeader->xlp_rem_len,
989-
(uint32) (state->recordContRecPtr >> 32),
990-
(uint32) state->recordContRecPtr,
991-
(uint32) (state->DecodeRecPtr >> 32),
992-
(uint32) state->DecodeRecPtr,
986+
LSN_FORMAT_ARGS(state->recordContRecPtr),
987+
LSN_FORMAT_ARGS(state->DecodeRecPtr),
993988
state->recordRemainLen);
994989
goto err;
995990
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy