From: Bruce Momjian Date: Fri, 23 Mar 2007 03:16:39 +0000 (+0000) Subject: Cleanup for procarray.c. X-Git-Tag: REL9_0_0~5849 X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=1e2bfb58110cf6d125b4dda3dc670444ff1b9d2c;p=pg-rex%2Fsyncrep.git Cleanup for procarray.c. --- diff --git a/src/backend/storage/ipc/procarray.c b/src/backend/storage/ipc/procarray.c index 19e5efa683..d2d39770c5 100644 --- a/src/backend/storage/ipc/procarray.c +++ b/src/backend/storage/ipc/procarray.c @@ -23,7 +23,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/storage/ipc/procarray.c,v 1.21 2007/01/16 13:28:56 alvherre Exp $ + * $PostgreSQL: pgsql/src/backend/storage/ipc/procarray.c,v 1.22 2007/03/23 03:16:39 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -590,6 +590,11 @@ GetSnapshotData(Snapshot snapshot, bool serializable) xmax = ReadNewTransactionId(); + /* + * Spin over procArray checking xid, xmin, and subxids. The goal is + * to gather all active xids, find the lowest xmin, and try to record + * subxids. + */ for (index = 0; index < arrayP->numProcs; index++) { PGPROC *proc = arrayP->procs[index]; @@ -614,8 +619,7 @@ GetSnapshotData(Snapshot snapshot, bool serializable) if (TransactionIdPrecedes(xid, xmin)) xmin = xid; - snapshot->xip[count] = xid; - count++; + snapshot->xip[count++] = xid; /* Update globalxmin to be the smallest valid xmin */ xid = proc->xmin;