Skip to content

Commit 174a513

Browse files
committed
Cosmetic fixes for KnownAssignedXidsGetOldestXmin, per Fujii Masao.
1 parent eb36d1a commit 174a513

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

src/backend/storage/ipc/procarray.c

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
*
3838
*
3939
* IDENTIFICATION
40-
* $PostgreSQL: pgsql/src/backend/storage/ipc/procarray.c,v 1.74 2010/08/30 14:16:48 sriggs Exp $
40+
* $PostgreSQL: pgsql/src/backend/storage/ipc/procarray.c,v 1.75 2010/08/30 17:30:44 tgl Exp $
4141
*
4242
*-------------------------------------------------------------------------
4343
*/
@@ -156,7 +156,7 @@ static int KnownAssignedXidsGet(TransactionId *xarray, TransactionId xmax);
156156
static int KnownAssignedXidsGetAndSetXmin(TransactionId *xarray,
157157
TransactionId *xmin,
158158
TransactionId xmax);
159-
static int KnownAssignedXidsGetOldestXmin(void);
159+
static TransactionId KnownAssignedXidsGetOldestXmin(void);
160160
static void KnownAssignedXidsDisplay(int trace_level);
161161

162162
/*
@@ -564,7 +564,7 @@ ProcArrayApplyRecoveryInfo(RunningTransactions running)
564564

565565
/*
566566
* Now we have a copy of any KnownAssignedXids we can zero the array
567-
* before we re-insertion of combined snapshot.
567+
* before we re-insert combined snapshot.
568568
*/
569569
KnownAssignedXidsRemovePreceding(InvalidTransactionId);
570570

@@ -1120,6 +1120,7 @@ GetOldestXmin(bool allDbs, bool ignoreVacuum)
11201120
* older than the main procarray.
11211121
*/
11221122
TransactionId kaxmin = KnownAssignedXidsGetOldestXmin();
1123+
11231124
if (TransactionIdIsNormal(kaxmin) &&
11241125
TransactionIdPrecedes(kaxmin, result))
11251126
result = kaxmin;
@@ -3028,7 +3029,11 @@ KnownAssignedXidsGetAndSetXmin(TransactionId *xarray, TransactionId *xmin,
30283029
return count;
30293030
}
30303031

3031-
static int
3032+
/*
3033+
* Get oldest XID in the KnownAssignedXids array, or InvalidTransactionId
3034+
* if nothing there.
3035+
*/
3036+
static TransactionId
30323037
KnownAssignedXidsGetOldestXmin(void)
30333038
{
30343039
/* use volatile pointer to prevent code rearrangement */

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