Content-Length: 271620 | pFad | http://github.com/postgrespro/postgres_cluster/commit/d01fc51c003ce6e7b0ac96204a1d82f1ba505b70

7C Initialize replication_slot_catalog_xmin in procarray · postgrespro/postgres_cluster@d01fc51 · GitHub
Skip to content

Commit d01fc51

Browse files
committed
Initialize replication_slot_catalog_xmin in procarray
Although not confirmed and probably rare, if the newly allocated memory is not already zero, this could possibly have caused some problems. Also reorder the initializations slightly so they match the order of the struct definition. Author: Wong, Yi Wen <yiwong@amazon.com> Reviewed-by: Masahiko Sawada <sawada.mshk@gmail.com>
1 parent dce90c7 commit d01fc51

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/backend/storage/ipc/procarray.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,13 +239,14 @@ CreateSharedProcArray(void)
239239
*/
240240
procArray->numProcs = 0;
241241
procArray->maxProcs = PROCARRAY_MAXPROCS;
242-
procArray->replication_slot_xmin = InvalidTransactionId;
243242
procArray->maxKnownAssignedXids = TOTAL_MAX_CACHED_SUBXIDS;
244243
procArray->numKnownAssignedXids = 0;
245244
procArray->tailKnownAssignedXids = 0;
246245
procArray->headKnownAssignedXids = 0;
247246
SpinLockInit(&procArray->known_assigned_xids_lck);
248247
procArray->lastOverflowedXid = InvalidTransactionId;
248+
procArray->replication_slot_xmin = InvalidTransactionId;
249+
procArray->replication_slot_catalog_xmin = InvalidTransactionId;
249250
}
250251

251252
allProcs = ProcGlobal->allProcs;

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/postgrespro/postgres_cluster/commit/d01fc51c003ce6e7b0ac96204a1d82f1ba505b70

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy