aboutsummaryrefslogtreecommitdiff
path: root/src/backend/storage/ipc/standby.c
diff options
context:
space:
mode:
authorPeter Eisentraut <peter@eisentraut.org>2021-02-23 10:14:38 +0100
committerPeter Eisentraut <peter@eisentraut.org>2021-02-23 10:27:02 +0100
commit6f6f284c7ee44264eb3e128e2bf54d9276711d11 (patch)
treec861d32584f751b28a065b98c03e1dd1370daa10 /src/backend/storage/ipc/standby.c
parentade89ba5f408e6034db7cc8a2c9b7858f5a214c4 (diff)
downloadpostgresql-6f6f284c7ee44264eb3e128e2bf54d9276711d11.tar.gz
postgresql-6f6f284c7ee44264eb3e128e2bf54d9276711d11.zip
Simplify printing of LSNs
Add a macro LSN_FORMAT_ARGS for use in printf-style printing of LSNs. Convert all applicable code to use it. Reviewed-by: Ashutosh Bapat <ashutosh.bapat@enterprisedb.com> Reviewed-by: Kyotaro Horiguchi <horikyota.ntt@gmail.com> Reviewed-by: Michael Paquier <michael@paquier.xyz> Discussion: https://www.postgresql.org/message-id/flat/CAExHW5ub5NaTELZ3hJUCE6amuvqAtsSxc7O+uK7y4t9Rrk23cw@mail.gmail.com
Diffstat (limited to 'src/backend/storage/ipc/standby.c')
-rw-r--r--src/backend/storage/ipc/standby.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backend/storage/ipc/standby.c b/src/backend/storage/ipc/standby.c
index 5877a60715f..a3ee652030c 100644
--- a/src/backend/storage/ipc/standby.c
+++ b/src/backend/storage/ipc/standby.c
@@ -1262,7 +1262,7 @@ LogCurrentRunningXacts(RunningTransactions CurrRunningXacts)
elog(trace_recovery(DEBUG2),
"snapshot of %u running transactions overflowed (lsn %X/%X oldest xid %u latest complete %u next xid %u)",
CurrRunningXacts->xcnt,
- (uint32) (recptr >> 32), (uint32) recptr,
+ LSN_FORMAT_ARGS(recptr),
CurrRunningXacts->oldestRunningXid,
CurrRunningXacts->latestCompletedXid,
CurrRunningXacts->nextXid);
@@ -1270,7 +1270,7 @@ LogCurrentRunningXacts(RunningTransactions CurrRunningXacts)
elog(trace_recovery(DEBUG2),
"snapshot of %u+%u running transaction ids (lsn %X/%X oldest xid %u latest complete %u next xid %u)",
CurrRunningXacts->xcnt, CurrRunningXacts->subxcnt,
- (uint32) (recptr >> 32), (uint32) recptr,
+ LSN_FORMAT_ARGS(recptr),
CurrRunningXacts->oldestRunningXid,
CurrRunningXacts->latestCompletedXid,
CurrRunningXacts->nextXid);