From 555b1ddf4daa983a539a1ef0461bffe15f8d5711 Mon Sep 17 00:00:00 2001 From: Anthonin Bonnefoy Date: Fri, 13 Feb 2026 09:22:45 +0100 Subject: Zero pad bytes of xl_running_xacts xl_running_xacts has 3 padding bytes after subxid_overflow which are currently uninitialized. When the struct is written, those uninitialized bytes are also written in the WAL. This patch ensures those pad bytes are zeroed. --- src/backend/storage/ipc/standby.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/backend/storage/ipc/standby.c b/src/backend/storage/ipc/standby.c index 7fa8d9247e0..4db944c3a16 100644 --- a/src/backend/storage/ipc/standby.c +++ b/src/backend/storage/ipc/standby.c @@ -1355,6 +1355,7 @@ LogCurrentRunningXacts(RunningTransactions CurrRunningXacts) xl_running_xacts xlrec; XLogRecPtr recptr; + MemSet(&xlrec, 0, sizeof(xl_running_xacts)); xlrec.xcnt = CurrRunningXacts->xcnt; xlrec.subxcnt = CurrRunningXacts->subxcnt; xlrec.subxid_overflow = (CurrRunningXacts->subxid_status != SUBXIDS_IN_ARRAY); -- 2.52.0